Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
#!/usr/bin/python | |
import socket | |
import struct | |
import sys | |
# We want unbuffered stdout so we can provide live feedback for | |
# each TTL. You could also use the "-u" flag to Python. | |
class flushfile(file): | |
def __init__(self, f): |
#!/bin/bash -e | |
clear | |
echo "============================================" | |
echo "WordPress Install Script" | |
echo "============================================" | |
echo "Database Name: " | |
read -e dbname | |
echo "Database User: " | |
read -e dbuser | |
echo "Database Password: " |
import base64 | |
import json | |
import matplotlib, matplotlib.pyplot | |
import numpy | |
import types | |
def show_plot(width, height=None): | |
""" | |
A decorator -- show the matplotlib plot after `f` completes. | |
Takes optional parameters (width, height) determining the size of the plot. |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
""" | |
MIT License | |
Copyright (c) 2017 Cyrille Rossant | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is |
# The MIT License (MIT) | |
# Copyright (c) 2016 Vladimir Ignatev | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining | |
# a copy of this software and associated documentation files (the "Software"), | |
# to deal in the Software without restriction, including without limitation | |
# the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
# and/or sell copies of the Software, and to permit persons to whom the Software | |
# is furnished to do so, subject to the following conditions: | |
# |
OP_DEPTH 3 OP_EQUAL | |
OP_IF | |
OP_HASH160 <hash160(R)> OP_EQUALVERIFY | |
OP_0 2 <AlicePubkey1> <BobPubkey1> 2 OP_CHECKMULTISIG | |
OP_ELSE | |
OP_0 2 <AlicePubkey2> <BobPubkey2> 2 OP_CHECKMULTISIG | |
OP_END |
ffmpeg -i input_file.mp4 -vf scale=320:-1:flags=lanczos,fps=30 frames/ffout%03d.png | |
convert -loop 0 frames/ffout*.png output_file.gif |
The following is some nba articles fully-automatically generated by char-cnn, a recurrent-neural-network library thanks to Andrej Karpathy [link]. The library is awesome to easy, and very user-friendly. You should try it! :)
Basically, I wrote a python script [link] to extract past archives . And use that as the training set for the recurrent neural network.
The articles below are generated by a network trained with rougly about 2 millions character (which is an okay size; not big enough though). You can see that the generated article contains artificial author names, speeches, etc; similar to an nba archive (although the logic has to be improved, it is FUN.)
You can tune the parameter and train with a even bigger dataset using my script. And you will probably get better result! Have fun:)