#List of countries / Список стран
ISO 3166-1
En list forked from https://gist.github.com/396531
from datetime import datetime | |
def generate_payment_ref(email, method, country): | |
""" | |
Generates a unique payment reference that will be sent to the payment provider. | |
Examples of returned references: | |
- [email protected] | |
- [email protected] | |
- [email protected] |
# 1. Create dynamic body depending on status | |
if user_status == "paid": | |
body = f"Hello paid user: {user.first_name} {user_status}" | |
else: | |
body = f"Hello not paid user: {user.first_name} {user_status}" | |
# 2. Add it to recipient email substitutions | |
to_emails.append( | |
To( | |
email=user.user_email, |
// Derived from paste at https://pastebin.com/iwqG6zvH | |
// Lightly edited to make it run | |
// Original discussion: https://t.me/GolangTZ/475 | |
// You can edit this code! | |
// Click here and start typing. | |
package main | |
import ( | |
"bufio" |
# Customize Bash PS1 prompt to show current status of active Git branch. | |
# Adapted from and inspired by http://mediadoneright.com/content/ultimate-git-ps1-bash-prompt | |
# Slightly faster prompt, as measured on my machine (TM) | |
# | |
# By @muendelezaji, Oct 2015 | |
# Skip if in zsh | |
[ "$ZSH" ] && return 0 | |
# SETUP CONSTANTS |
# Author: Randal S. Olson (randalolson.com / @randal_olson) | |
# Uses Tableau's Tableau10 color scheme | |
# | |
# In Notebook, use it as follows: | |
# plt.style.use('https://gist.githubusercontent.com/muendelezaji/75fe7ca33ac3b47730ba85378459a206/raw/1b807615235ff6f4c919b5b70b01a609619e1e9c/tableau10.mplstyle') | |
figure.figsize: 12, 7 | |
figure.edgecolor: white | |
figure.facecolor: white |
#List of countries / Список стран
ISO 3166-1
En list forked from https://gist.github.com/396531
From b5a99e2174f115f87c0cb3de9d2a2479a0193db2 Mon Sep 17 00:00:00 2001 | |
From: Koan-Sin Tan <[email protected]> | |
Date: Sun, 18 Nov 2018 13:11:38 +0800 | |
Subject: [PATCH 1/3] add cmdline option to allow running fp32 models with fp16 | |
Add an option for TFLite benchmark_model to allow running fp32 | |
models with fp16. Useful when testing NNPAI accelerators with | |
fp16. | |
--- | |
.../lite/tools/benchmark/benchmark_tflite_model.cc | 9 ++++++++- |
#!/bin/bash | |
# ============================================================= | |
# UPDATE SOURCE | |
# ============================================================= | |
# git clone https://github.com/tensorflow/tensorflow | |
# git checkout -- . | |
# git pull origin master | |
# TF_BRANCH=r1.8 | |
TF_ROOT=/home/tensorflow |
# Docker | |
FROM ubuntu:xenial | |
# Install developer tools | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN apt-get -y update && apt-get -y install \ | |
build-essential \ | |
g++-arm-linux-gnueabihf \ | |
git \ | |
openjdk-8-jdk \ |
import java.io.BufferedReader; | |
import java.io.BufferedWriter; | |
import java.io.IOException; | |
import java.lang.StringBuilder; | |
import java.nio.file.attribute.BasicFileAttributes; | |
import java.nio.file.Files; | |
import java.nio.file.FileSystems; | |
import java.nio.file.FileVisitResult; | |
import java.nio.file.Path; | |
import java.nio.file.Paths; |