vanheeringen-lab / ANANSE

Prediction of key transcription factors in cell fate determination using enhancer networks. See full ANANSE documentation for detailed installation instructions and usage examples.
http://anansepy.readthedocs.io
MIT License
77 stars 16 forks source link

different array shape leads to proba crash #147

Closed JGASmits closed 2 years ago

JGASmits commented 2 years ago

When running a fresh conda install of Ananse (so the master brench), it crashes on binding. I'm checking (in a bit) which package is different between my old 'master conda env' and the newly generated one. I gues its because some package updated which is breaking stuff. You can probably replicate the bug by installing Ananse from conda, and running binding with more than 200.000 regions.

2021-10-25 00:09:48 | INFO | No related TF found for ZNF418, using general model
2021-10-25 00:09:48 | DEBUG | Shape of passed values is (200000, 1), indices imply (357758, 1)
2021-10-25 00:09:48 | INFO | No match for ZNF140 based on motifs
2021-10-25 00:09:48 | INFO | No related TF found for ZNF140, using general model
2021-10-25 00:09:48 | DEBUG | Shape of passed values is (200000, 1), indices imply (357758, 1)
2021-10-25 00:09:48 | INFO | Using ENO1 motif with MYC model weights
2021-10-25 00:09:49 | DEBUG | Shape of passed values is (200000, 1), indices imply (357758, 1)
Traceback (most recent call last):
  File "/vol/mbconda/jsmits/envs/ananse_master/bin/ananse", line 369, in <module>
    args.func(args)
  File "/vol/mbconda/jsmits/envs/ananse_master/lib/python3.9/site-packages/ananse/commands/binding.py", line 12, in binding
    predict_peaks(
  File "/vol/mbconda/jsmits/envs/ananse_master/lib/python3.9/site-packages/ananse/peakpredictor.py", line 792, in predict_peaks
    hdf.put(key="_index", value=proba.index.to_series(), format="table")
UnboundLocalError: local variable 'proba' referenced before assignment
simonvh commented 2 years ago

My guess is sickit-learn? The error is in model prediction, and scikit-learn has recently been updated.