Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Saving output to a separate path in dsps demo notebook #145

Open
2 of 3 tasks
hangqianjun opened this issue May 28, 2024 · 0 comments
Open
2 of 3 tasks

Saving output to a separate path in dsps demo notebook #145

hangqianjun opened this issue May 28, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@hangqianjun
Copy link
Contributor

hangqianjun commented May 28, 2024

Bug report

This bug occurs when we try to run dsps notebook on nersc environment desc-python-bleed. The output data is trying to write into the conda installation area even if a global outdir is given. Below is a copy of the error report:

OSError                                   Traceback (most recent call last)
Cell In[3], line 16
     13 stellar_metallicity = np.full(n_galaxies, gal_lgmet)
     14 stellar_metallicity_scatter = np.full(n_galaxies, gal_lgmet_scatter)
---> 16 with h5py.File(trainFile, 'w') as h5table:
     17     h5table.create_dataset(name='redshifts', data=redshift)
     18     h5table.create_dataset(name='cosmic_time_grid', data=cosmic_time_grid)

File /opt/desc/py/lib/python3.10/site-packages/h5py/_hl/files.py:562, in File.__init__(self, name, mode, driver, libver, userblock_size, swmr, rdcc_nslots, rdcc_nbytes, rdcc_w0, track_order, fs_strategy, fs_persist, fs_threshold, fs_page_size, page_buf_size, min_meta_keep, min_raw_keep, locking, alignment_threshold, alignment_interval, meta_block_size, **kwds)
    553     fapl = make_fapl(driver, libver, rdcc_nslots, rdcc_nbytes, rdcc_w0,
    554                      locking, page_buf_size, min_meta_keep, min_raw_keep,
    555                      alignment_threshold=alignment_threshold,
    556                      alignment_interval=alignment_interval,
    557                      meta_block_size=meta_block_size,
    558                      **kwds)
    559     fcpl = make_fcpl(track_order=track_order, fs_strategy=fs_strategy,
    560                      fs_persist=fs_persist, fs_threshold=fs_threshold,
    561                      fs_page_size=fs_page_size)
--> 562     fid = make_fid(name, mode, userblock_size, fapl, fcpl, swmr=swmr)
    564 if isinstance(libver, tuple):
    565     self._libver = libver

File /opt/desc/py/lib/python3.10/site-packages/h5py/_hl/files.py:241, in make_fid(name, mode, userblock_size, fapl, fcpl, swmr)
    239     fid = h5f.create(name, h5f.ACC_EXCL, fapl=fapl, fcpl=fcpl)
    240 elif mode == 'w':
--> 241     fid = h5f.create(name, h5f.ACC_TRUNC, fapl=fapl, fcpl=fcpl)
    242 elif mode == 'a':
    243     # Open in append mode (read/write).
    244     # If that fails, create a new file only if it won't clobber an
    245     # existing one (ACC_EXCL)
    246     try:

File h5py/_objects.pyx:54, in h5py._objects.with_phil.wrapper()

File h5py/_objects.pyx:55, in h5py._objects.with_phil.wrapper()

File h5py/h5f.pyx:122, in h5py.h5f.create()

OSError: [Errno 30] Unable to synchronously create file (unable to open file: name = '/opt/desc/py/lib/python3.10/sitepackages/rail/examples_data/creation_data/data/dsps_default_data/input_galaxy_properties_dsps.hdf5',

Before submitting
Please check the following:

  • I have described the situation in which the bug arose, including what code was executed, information about my environment, and any applicable data others will need to reproduce the problem.
  • I have included available evidence of the unexpected behavior (including error messages, screenshots, and/or plots) as well as a descriprion of what I expected instead.
  • If I have a solution in mind, I have provided an explanation and/or pseudocode and/or task list.
@hangqianjun hangqianjun added the bug Something isn't working label May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants