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 dask | |
import numpy as np | |
import pandas as pd | |
import dask.dataframe as ddf | |
dask_chunks = 20 | |
# Partition the dataframe | |
slices = [ | |
np.datetime64(d) |
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
from IPython.display import HTML | |
style = "<style>#output-body{display:flex; flex-direction: row;}</style>" | |
display(HTML(style)) | |
display(SVG('level_0_eval/cg.svg')) | |
display(SVG('level_0_eval/cg.svg')) |
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
#!/bin/bash | |
mkdir /etc/resilio | |
cd /etc/resilio | |
wget -N --no-check-certificate https://download-cdn.resilio.com/stable/linux-arm/resilio-sync_arm.tar.gz | |
tar xvzf resilio-sync_arm.tar.gz | |
rm resilio-sync_arm.tar.gz | |
wget -N --no-check-certificate https://gist.githubusercontent.com/P8H/379f5e48a66794311fefd86e74022d54/raw/resilio.conf | |
cd /etc/init.d/ | |
wget -N --no-check-certificate https://gist.githubusercontent.com/P8H/379f5e48a66794311fefd86e74022d54/raw/resiliod | |
e |
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 org.nd4j.jita.conf.CudaEnvironment; | |
import org.nd4j.jita.conf.Configuration; | |
public class TestClass { | |
public static void main(String[] args) throws Exception { | |
CudaEnvironment.getInstance().getConfiguration().allowMultiGPU(true); //Use all available GPUs | |
DataTypeUtil.setDTypeForContext(DataBuffer.Type.HALF); //Use half precision, boost learning up to 200% | |
CudaEnvironment.getInstance().getConfiguration() | |
.setMaximumDeviceCacheableLength(1024 * 1024 * 1024L) |
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 org.deeplearning4j.datasets.fetchers.MnistDataFetcher; | |
import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; | |
import org.deeplearning4j.nn.api.OptimizationAlgorithm; | |
import org.deeplearning4j.nn.conf.MultiLayerConfiguration; | |
import org.deeplearning4j.nn.conf.NeuralNetConfiguration; | |
import org.deeplearning4j.nn.conf.layers.OutputLayer; | |
import org.deeplearning4j.nn.conf.layers.RBM; | |
import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; |
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
% synthetic dataset for multiple-instance learning using standard MI assumption. | |
@relation demo1 | |
@attribute bag_XY {BAGN-1,BAGN-2,BAGP-3} | |
@attribute bag relational | |
@attribute f1 numeric | |
@attribute f2 numeric | |
@end bag |
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
# Watchdog install script for raspberry pi | |
# based on http://binerry.de/post/28263824530/raspberry-pi-watchdog-timer | |
# first think about to update the firmaware: rpi-update | |
sudo bash | |
apt-get install watchdog chkconfig | |
modprobe bcm2708_wdog | |
echo "WantedBy=multi-user.target" >> /lib/systemd/system/watchdog.service | |
# http://raspberrypi.stackexchange.com/a/33901 |
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
from multiprocessing.managers import BaseManager | |
class IPC(BaseManager): | |
"""Little example how to provide a shutdown() function if you us the serve_forever method | |
""""" | |
_server_object = None # docs.python.org/3.5/library/multiprocessing.html#multiprocessing.managers.BaseManager | |
def __init__(self): | |
BaseManager.__init__(self, address=('127.0.0.1', 4000), authkey=b'42') |