deepskies / deeplenstronomy

A pipeline for versatile strong lens sample simulations
MIT License
26 stars 7 forks source link

create h5 outputs #98

Closed bnord closed 1 year ago

jsv1206 commented 1 year ago

To create h5 output

dataset = dl.make_dataset('xxx.yaml', verbose=True, save_to_disk=True, image_file_format='h5')

To read an existing h5 output from Lenstornomy f = h5py.File('OUTDIR/CONFIGURATION_1_images.h5', 'r') dset = f['NAME']

OUTDIR is the one mentioned in the yaml file NAME is the dataset name given in the yaml file

dset is now numpy array similar to npy output which is read using np.load()

jsv1206 commented 1 year ago

Add documentation to Saving Datasets in /Notebooks/DeepLenstronomyDemo.ipynb