Created
August 10, 2020 07:55
-
-
Save henry2man/4408cf391c8eab02d1f30528bf5a0a48 to your computer and use it in GitHub Desktop.
Quick & dirty solution to use an external mounted hard drive under Ubuntu to transparently store both Tensorflow & Keras datasets, in order to preserve fast SSD space.
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 | |
# Mounted Hard drive path | |
drive_path = /media/data/dl | |
# Create main dir | |
mkdir $drive_path | |
# Create folders | |
mkdir $drive_path/keras_datasets | |
# Or "mv ~/tensorflow_datasets $drive_path/keras_datasets" if already exists | |
mkdir $drive_path/tensorflow_datasets | |
# Or "mv ~/.keras/datasets $drive_path/tensorflow_datasets" if already exists | |
# Create symlinks | |
ln -s $drive_path/keras_datasets ~/.keras/datasets | |
ln -s $drive_path/tensorflow_datasets ~/tensorflow_datasets |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment