Repository for SFH inference hackathon at AstroInfo 2021.
Proposed by: Marc Huertas-Company, Francois Lanusse, Alexandre Boucaud
See this issue to get started.
-
Log on the machine
-
Clone this repo
git clone https://github.com/EiffL/sfh-inference-hackathon.git
- Load the environment
module load tensorflow-gpu/py3/2.6.0
- Start an interactive session
srun --ntasks=1 --cpus-per-task=10 --gres=gpu:1 --hint=nomultithread --time=06:00:00 -A wvb@gpu --pty bash
- Start a jupyter lab
idrlab --notebook-dir=$PWD
And then follow the link to https://idrvprox.idris.fr, log in, and click on your submitted job.
Then you can try to load the intro notebook
There is a sfh
module whose code lies in code/sfh
. The code that is used
in several notebooks, or code that shall be ran outside of notebooks, shall be
included in it.
One way to install it for your environment on Jean Zay you can do:
cd sfh-inference-hackathon
pip install --user -e .
To customize the location of the data, it is possible to use two environment variables:
TNG100_DATA_PATH
contains the path to the TNG100 data.TFDS_DATA_DIR
contains the path to the tensorflow datasets.
And then use the function sfh.datasets.setup_environment
. On Jean Zay,
there's no need to define these two environment variables and the function will
set them automatically.
from sfh.datasets import setup_environment, tng100, eagle
import tensorflow_datasets as tfds
setup_environment()
dset_tng100 = tfds.load('tng100', split='train')
dset_eagle = tfds.load('eagle', split='train')