docker run -it -u $(id -u):$(id -g) -w $PWD -v /mnt:/mnt pangyuteng/dcm:latest bash
apt-get install wkhtmltopdf
pip install imgkit,pdfkit,jinja2
This file contains hidden or 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
.env | |
*.nii.gz | |
tmp |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<style> | |
body { | |
font-family: Helvetica Neue, Arial, sans-serif; | |
text-align: center; | |
} | |
.wrapper { | |
max-width: 800px; | |
margin: 50px auto; |
This file contains hidden or 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
_BrBG_data = ( | |
(0.32941176470588235, 0.18823529411764706, 0.0196078431372549 ), | |
(0.5490196078431373 , 0.31764705882352939, 0.0392156862745098 ), | |
(0.74901960784313726, 0.50588235294117645, 0.17647058823529413), | |
(0.87450980392156863, 0.76078431372549016, 0.49019607843137253), | |
(0.96470588235294119, 0.90980392156862744, 0.76470588235294112), | |
(0.96078431372549022, 0.96078431372549022, 0.96078431372549022), | |
(0.7803921568627451 , 0.91764705882352937, 0.89803921568627454), | |
(0.50196078431372548, 0.80392156862745101, 0.75686274509803919), |
- follow https://github.com/awslabs/amazon-sagemaker-examples/tree/master/advanced_functionality/scikit_bring_your_own
- prior building and pushing docker container manually create ECR, and create role for sagemaker (https://console.aws.amazon.com/ecs)
- TODO: -- invocation with cli or http -- authentication required https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html -- potential alternative? https://medium.com/@julsimon/using-chalice-to-serve-sagemaker-predictions-a2015c02b033
This file contains hidden or 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 | |
set -e | |
g++ -o test_offscreen.o -c test_offscreen.cpp -I$PYTHONHPC/include/vtk-6.0 | |
g++ -o test_offscreen test_offscreen.o $PYTHONHPC/lib/libvtk*.so | |
LD_LIBRARY_PATH=$PYTHONHPC/lib/ ./test_offscreen |
This file contains hidden or 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
sudo su - | |
# go to system root, cd .. | |
mkdir /opt/anaconda3 | |
# installed anaconda to /opt/anaconda3 | |
bash /Temp/Anaconda3-5.1.0-Linux-x86_64.sh | |
# create py 3.6 | |
/opt/anaconda3/bin/conda create -p /opt/envs/conda/py36 python=3.6 | |
# activate py 3.6 | |
source /opt/anaconda3/bin/activate /opt/envs/conda/py36 | |
# install prebuilt vtk for offscreen rendering |
conda create -n py27 python=2.7
activate py27
conda install -c intel mkl
conda install numpy scipy six
pip install nibabel
conda install -c conda-forge dipy
pip install https://github.com/samuelstjean/spams-python/releases/download/v2.6/spams-2.4-cp27-none-win_amd64.whl
pip install git+https://github.com/daducci/AMICO.git
This file contains hidden or 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 python | |
import os | |
os.environ['CUDA_VISIBLE_DEVICES'] = '' | |
import pandas as pd | |
import numpy as np | |
from keras import optimizers | |
from keras.utils import to_categorical | |
from keras.models import Model | |
from keras.layers import Input, Dense |