crawlik / whale-id

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Id a whale

Project Instructions

  1. Clone the repository and navigate to the downloaded folder.
git clone git@github.com:crawlik/whale-id.git
cd whale-id
  1. Create and activate a new environment.
conda create -y -n whale-id python=3.6
source activate whale-id
pip install -r requirements.txt
# If running on GPU
pip install -r requirements-gpu.txt
# Optional: install optimized TF from https://github.com/lakshayg/tensorflow-build
# 2.9 GHz Intel Core i7, OSX Sierra
pip install --ignore-installed --upgrade "https://github.com/lakshayg/tensorflow-build/raw/master/tensorflow-1.8.0-cp36-cp36m-macosx_10_7_x86_64.whl"
  1. Download the data

You may need to install Kaggle API key.

kaggle competitions download -c whale-categorization-playground --wp
unzip train.zip
unzip test.zip
  1. Create an IPython kernel for the whale-id environment.
python -m ipykernel install --user --name whale-id --display-name "whale-id"
  1. Open training notebook.
jupyter notebook whale-id-all.ipynb

Running notebook remotely on a headless server.

jupyter notebook --ip=0.0.0.0 --no-browser whale-id-all.ipynb

Training logs to tensordboard and data can be viewed by

tensorboard --logdir=./logs/
  1. Before running code, change the kernel to match the whale-id environment by using the drop-down menu (Kernel > Change kernel > whale-id). Then, follow the instructions in the notebook.

  2. Open classification notebook

jupyter notebook classify.ipynb
  1. Generate report
jupyter notebook report.ipynb
  1. Run attention and CNN visualization
jupyter notebook attention.ipynb
jupyter notebook keras-vis.ipynb
pip install -r requirements.txt

About


Languages

Language:HTML 65.8%Language:Jupyter Notebook 34.2%