velocyto-team / velocyto.py

RNA velocity estimation in Python
http://velocyto.org/velocyto.py/
BSD 2-Clause "Simplified" License
159 stars 82 forks source link

UnboundLocalError: local variable 'total' referenced before assignment #174

Open somnathtagore opened 5 years ago

somnathtagore commented 5 years ago

Hi,

I encountered these two errors while running velocyto... the loom file is created.

2019-02-03 22:25:37,857 - DEBUG - Counting done! 2019-02-03 22:25:38,494 - DEBUG - Example of barcode: AGGGTGAGTCGAGTTT and cell_id: output_LDTK3:AGGGTGAGTCGAGTTT 2019-02-03 22:25:38,549 - DEBUG - Generating output file /...../velocyto/output_LDTK3.loom 2019-02-03 22:25:38,549 - DEBUG - Collecting row attributes 2019-02-03 22:25:39,429 - DEBUG - Generating data table Traceback (most recent call last): File "/.../rna-velocity/velocyto.py-master/velocyto/commands/_run.py", line 280, in _run total += layers[layer_name] UnboundLocalError: local variable 'total' referenced before assignment

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/.../anaconda3/envs/my_pymc_env/bin/velocyto", line 11, in load_entry_point('velocyto', 'console_scripts', 'velocyto')() File "/.../anaconda3/envs/my_pymc_env/lib/python3.7/site-packages/click/core.py", line 764, in call return self.main(args, kwargs) File "/.../anaconda3/envs/my_pymc_env/lib/python3.7/site-packages/click/core.py", line 717, in main rv = self.invoke(ctx) File "/.../anaconda3/envs/my_pymc_env/lib/python3.7/site-packages/click/core.py", line 1137, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/ifs/home/c2b2/ac_lab/st3179/anaconda3/envs/my_pymc_env/lib/python3.7/site-packages/click/core.py", line 956, in invoke return ctx.invoke(self.callback, ctx.params) File "/.../anaconda3/envs/my_pymc_env/lib/python3.7/site-packages/click/core.py", line 555, in invoke return callback(args, kwargs) File "/.../rna-velocity/velocyto.py-master/velocyto/commands/run.py", line 113, in run samtools_memory=samtools_memory, dump=dump, verbose=verbose, additional_ca=additional_ca) File "/.../rna-velocity/velocyto.py-master/velocyto/commands/_run.py", line 282, in _run total = np.array(layers[layer_name]) MemoryError**

Just to let you know i assigned 46G as vmem.

Many thanks!

gioelelm commented 5 years ago

Have you looked at all the other solved issues about memory problems?