Can't access hdf5 files with openPMD on an external hard_drive
Closed this issue · 3 comments
andrefantoine commented
When I try to access my h5 files with openpmd (specifically on an external harddrive) I get an error (see below). I don;t have this issue on the C:/ drive but obviously the files can be memory intensive.
FileNotFoundError Traceback (most recent call last)
<ipython-input-4-9e837cfe409f> in <module>
----> 1 ts_2d = LpaDiagnostics('./example-2d/hdf5/')
2 # ts_2d = LpaDiagnostics('./hdf5/')
~\Anaconda3\lib\site-packages\openpmd_viewer\addons\pic\lpa_diagnostics.py in __init__(self, path_to_dir, check_all_files)
47 """
48 OpenPMDTimeSeries.__init__( self, path_to_dir,
---> 49 check_all_files=check_all_files )
50
51 def get_mean_gamma( self, t=None, iteration=None, species=None,
~\Anaconda3\lib\site-packages\openpmd_viewer\openpmd_timeseries\main.py in __init__(self, path_to_dir, check_all_files)
63 """
64 # Extract the files and the iterations
---> 65 self.h5_files, self.iterations = list_h5_files(path_to_dir)
66
67 # Check that there are HDF5 files in this directory
~\Anaconda3\lib\site-packages\openpmd_viewer\openpmd_timeseries\utilities.py in list_h5_files(path_to_dir)
73 """
74 # Find all the files in the provided directory
---> 75 all_files = os.listdir(path_to_dir)
76
77 # Select the hdf5 files
FileNotFoundError: [WinError 3] The system cannot find the path specified: './example-2d/hdf5/'
The LpaDiagnostics class inherits from the OpenPMDTimeSeries class, and therefore it also has the methods get_field, get_particle and slider. For instance:
RemiLehe commented
Sorry for the late reply!
Quick question: Are you sure that the path that you provide is the correct one?
Could you do
!pwd
!ls ./example-2d/hdf5/
from your Jupyter notebook, just to check that the path is correct?
andrefantoine commented
Hi Remi,
Sorry for the late reply, a lot of changes obviously due to the
coronavirus. So I am sure that the path was correct. But interestingly, I
went to test it and I found that the pmdtimeseries mysteriously works now.
…On Mon, Mar 9, 2020 at 11:34 AM Remi Lehe ***@***.***> wrote:
Sorry for the late reply!
Quick question: Are you sure that the path that you provide is the correct
one?
Could you do
!pwd
!ls ./example-2d/hdf5/
from your Jupyter notebook, just to check that the path is correct?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#272?email_source=notifications&email_token=AL3ELQ6W5LDK3PNT25LHGHTRGULCPA5CNFSM4LCKT5WKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEOHXHZY#issuecomment-596603879>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AL3ELQZKEJGOVCIBH6IVEKDRGULCPANCNFSM4LCKT5WA>
.
--
Very Respectfully,
Andre F. Antoine
Ronald E. McNair Scholar
Imes Moore Fellow
Applied Physics Graduate Student
Optical Society U of M
Beat-The-Streets Wrestling Inc.
The University of Michigan
RemiLehe commented
OK, good to know. Thanks for letting me know.
Should I close this issue for now?