bonito icon indicating copy to clipboard operation
bonito copied to clipboard

Prediction error

Open Heiseweiye opened this issue 3 years ago • 3 comments

Hi, when I use basecaller to predict my fast5-file, the following errors happened:

Traceback (most recent call last):
  File "/home/wjw/anaconda3/envs/bonito-cu113/lib/python3.8/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
  File "/home/wjw/hswy/bonito/bonito/fast5.py", line 218, in get_meta_data
    Read(f5_fh.get_read(read_id), filename, meta=True)
  File "/home/wjw/hswy/bonito/bonito/fast5.py", line 35, in __init__
    self.sample_id = tracking_id['sample_id']
  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 "/home/wjw/anaconda3/envs/bonito-cu113/lib/python3.8/site-packages/h5py/_hl/attrs.py", line 56, in __getitem__
    attr = h5a.open(self._id, self._e(name))
  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/h5a.pyx", line 80, in h5py.h5a.open
KeyError: "Can't open attribute (can't locate attribute: 'sample_id')"

Heiseweiye avatar Jan 05 '22 09:01 Heiseweiye

Was this issue fixed?

dberma15 avatar May 16 '22 13:05 dberma15

@dberma15 sample_id isn't treated as optional in bonito. Are you seeing issues with this?

iiSeymour avatar May 16 '22 13:05 iiSeymour

@Heiseweiye Have you solved this problem, I also encountered this problem only when I basecaller some specific genome, such as "Klebsiella_pneumoniae_INF007". Could you share your solution?

HanielF avatar Oct 04 '22 17:10 HanielF

https://github.com/nanoporetech/bonito/commit/8c96eb894a9cbdd917c9797d8a4f5531c1dcb935 makes sample_id optional.

iiSeymour avatar May 31 '23 14:05 iiSeymour