Skip to content

Error plotting with SquigglePlot.py #51

@capoony

Description

@capoony

Hi,

unfortunately, I cannot get SquiggleKit to work. I closely followed your Installation tutorial and installed the required packages in a virtual environment.

cd /opt/bioinformatics

git clone https://github.com/Psy-Fer/SquiggleKit.git

python3 -m venv /opt/venv/SquiggleKit

source /opt/venv/SquiggleKit/bin/activate

pip install ont-fast5-api

pip install numpy h5py sklearn matplotlib

pip install pyslow5

When, I now run SquigglePlot.py on the test dataset in example/ I get the following error.

(base) [mkapun@nhm-phylo2 ~]$ source /opt/venv/SquiggleKit/bin/activate
(SquiggleKit) (base) [mkapun@nhm-phylo2 ~]$ cd SquiggleKit/
(SquiggleKit) (base) [mkapun@nhm-phylo2 SquiggleKit]$ python ./SquigglePlot.py -i example/test.fast5
Looking at the file example/test.fast5
Traceback (most recent call last):
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 364, in read_multi_fast5

    readID = hdf[read]['Raw'].attrs['read_id'].decode()
  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 "/opt/venv/SquiggleKit/lib/python3.8/site-packages/h5py/_hl/group.py", line 305, in __getitem__
    oid = h5o.open(self.id, self._e(name), lapl=self._lapl)
  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/h5o.pyx", line 190, in h5py.h5o.open
KeyError: "Unable to open object (object 'Raw' doesn't exist)"
extract_fast5():failed to read readID: AnalysesTraceback (most recent call last):
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 364, in read_multi_fast5
    readID = hdf[read]['Raw'].attrs['read_id'].decode()
  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 "/opt/venv/SquiggleKit/lib/python3.8/site-packages/h5py/_hl/group.py", line 305, in __getitem__
    oid = h5o.open(self.id, self._e(name), lapl=self._lapl)
  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/h5o.pyx", line 190, in h5py.h5o.open
KeyError: "Unable to open object (object 'Raw' doesn't exist)"
extract_fast5():failed to read readID: RawTraceback (most recent call last):
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 364, in read_multi_fast5
    readID = hdf[read]['Raw'].attrs['read_id'].decode()
  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 "/opt/venv/SquiggleKit/lib/python3.8/site-packages/h5py/_hl/group.py", line 305, in __getitem__
    oid = h5o.open(self.id, self._e(name), lapl=self._lapl)
  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/h5o.pyx", line 190, in h5py.h5o.open
KeyError: "Unable to open object (object 'Raw' doesn't exist)"
extract_fast5():failed to read readID: UniqueGlobalKeyTraceback (most recent call last):
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 459, in <module>
    main()
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 275, in main
    sigs = get_multi_fast5_signal(args, fast5)
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 344, in get_multi_fast5_signal
    signal = convert_to_pA_numpy(signal, f5_dic[read]['digitisation'], f5_dic[read]['range'], f5_dic[read]['offset'])
  File "/opt/bioinformatics/SquiggleKit/SquigglePlot.py", line 455, in convert_to_pA_numpy
    raw_unit = range / digitisation
ZeroDivisionError: float division by zero

Any help would be highly appreciated

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions