With the provided instructions the example run does not work in Python 3.10.8 using Apple M1 Pro macOS 13.5.
> pip --version
pip 23.2.1 from /opt/homebrew/lib/python3.11/site-packages/pip (python 3.11)
> ldmat submatrix examples/chr21_partial.h5 --row-start 14300001 --row-end 14400001
Assuming symmetric start positions
Assuming symmetric end positions
Traceback (most recent call last):
File "/opt/homebrew/bin/ldmat", line 8, in <module>
sys.exit(run_cli())
^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/ldmat/__init__.py", line 5, in run_cli
cli()
File "/opt/homebrew/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/ldmat/__main__.py", line 747, in wrapper
result = function(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/ldmat/__main__.py", line 847, in submatrix
h5py.File(ld_file, "r"), row_start, row_end, col_start, col_end, stream
^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/h5py/_hl/files.py", line 567, in __init__
fid = make_fid(name, mode, userblock_size, fapl, fcpl, swmr=swmr)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.11/site-packages/h5py/_hl/files.py", line 231, in make_fid
fid = h5f.open(name, flags, fapl=fapl)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "h5py/_objects.pyx", line 54, in h5py._objects.with_phil.wrapper
File "h5py/_objects.pyx", line 55, in h5py._objects.with_phil.wrapper
File "h5py/h5f.pyx", line 106, in h5py.h5f.open
OSError: Unable to open file (file signature not found)
The problem seems to be the installation script does not actually download the example files (due probably to the --depth param), instead it download the files with something like the following content
version https://git-lfs.github.com/spec/v1
oid sha256:b55da2913b06fc823aca0e6d1021870f4de8048ae0d7d513456ce413c4dd217b
size 61472255
With the provided instructions the example run does not work in Python 3.10.8 using Apple M1 Pro macOS 13.5.
The problem seems to be the installation script does not actually download the example files (due probably to the --depth param), instead it download the files with something like the following content