This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/usr/bin/env bash | |
###################################################################### | |
# Pipenv automatically assigns names to the virtual environments # | |
# based on a hash of the directory where the Pipfile resides. If # | |
# this directory is moved, then pipenv will no longer find the venv. # | |
# Not only does the virtual environment (venv) have to be renamed, # | |
# but all references to it (e.g., in shebangs) must also be updated. # | |
###################################################################### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
import requests | |
from tqdm import tqdm | |
from pprint import pprint | |
from itertools import islice | |
from urllib.parse import quote | |
from functools import lru_cache | |
from collections import Counter, OrderedDict |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"rust": { | |
"library": "extern crate serde_json; extern crate rustfmt;", | |
"prefix": "{ use std::fs::File; use serde_json::json; use crate::rustfmt::{format_input, Input, config::Config}; let config = Config::default(); let input = Input::Text(", | |
"postfix": ".into()); let (summary, filemap, _) = format_input::<File>(input, &config, Option::None).unwrap(); if summary.has_no_errors() { let (_, output) = &filemap[0]; println!(\"{}\", json!(output.to_string())); } }" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from kivy.utils import platform | |
if platform == 'android': | |
from jnius import autoclass | |
File = autoclass('java.io.File') | |
Interpreter = autoclass('org.tensorflow.lite.Interpreter') | |
InterpreterOptions = autoclass('org.tensorflow.lite.Interpreter$Options') | |
Tensor = autoclass('org.tensorflow.lite.Tensor') |