COSMIC-PopSynth / COSMIC

COSMIC (Compact Object Synthesis and Monte Carlo Investigation Code)
GNU General Public License v3.0
48 stars 59 forks source link

IO Error when running runFixedPop #203

Closed james-s-willis closed 5 years ago

james-s-willis commented 5 years ago

When running:

(cosmic) [willis@scarlet willis]$ runFixedPop --final_kstar1 11 --final_kstar2 10 11 --inifile Params.ini --galaxy_component ThinDisk --metallicity 0.02 --convergence-params mass_1 mass_2 sep ecc --initial_samp multidim --Nstep 15000 --Niter 1000000000 -n 2

I get the following IO error:

Opening dat_ThinDisk_11_10_11.h5 in read-only mode
Opening dat_ThinDisk_11_10_11.h5 in read-only mode
Traceback (most recent call last):
  File "/home/willis/anaconda2/envs/cosmic/bin/runFixedPop", line 201, in <module>
    dat_store = pd.HDFStore('dat_'+args.galaxy_component+'_'+kstar1_range_string+'_'+kstar2_range_string+'.h5')
  File "/home/willis/anaconda2/envs/cosmic/lib/python2.7/site-packages/pandas/io/pytables.py", line 488, in __init__
    self.open(mode=mode, **kwargs)
  File "/home/willis/anaconda2/envs/cosmic/lib/python2.7/site-packages/pandas/io/pytables.py", line 608, in open
    self._handle = tables.open_file(self._path, 'r', **kwargs)
  File "/home/willis/anaconda2/envs/cosmic/lib/python2.7/site-packages/tables/file.py", line 320, in open_file
    return File(filename, mode, title, root_uep, filters, **kwargs)
  File "/home/willis/anaconda2/envs/cosmic/lib/python2.7/site-packages/tables/file.py", line 784, in __init__
    self._g_new(filename, mode, **params)
  File "tables/hdf5extension.pyx", line 374, in tables.hdf5extension.File._g_new
  File "/home/willis/anaconda2/envs/cosmic/lib/python2.7/site-packages/tables/utils.py", line 157, in check_file_access
    raise IOError("``%s`` does not exist" % (filename,))
IOError: ``dat_ThinDisk_11_10_11.h5`` does not exist

I am following the documentation at: https://cosmic-popsynth.github.io/fixedpop/index.html#sample-command-line

I am running Ubuntu 18.04.2, Python 2.7.16, Anaconda 2019.03 and gfortran 7.4.0. @katiebreivik

scottcoughlin2014 commented 5 years ago

Hey @james-s-willis I tried to reproduce your issue, and am having trouble doing so. I am wondering if you could list the versions of pandas and h5py you have in your conda environment as well? The

Opening dat_ThinDisk_11_10_11.h5 in read-only mode

is odd and I have never seen that before in the standard out.

Also, not that we should not be backwards compatible, but I will probably need to set up a py27 virtualenv to really try to reproduce the error so may take a second.

Thanks!

Scotty

james-s-willis commented 5 years ago

Hi Scotty,

Thanks for the quick response. I tried the same command again today and it seems to be working now. So I was going to close this issue.

I was using h5py 2.9.0 and pandas 0.24.2

Thanks again,

James