orin-beep / hotspot Goto Github PK
View Code? Open in Web Editor NEWHOTSPOT is a hierarchical host prediction tool for plasmid contigs using Transformer.
HOTSPOT is a hierarchical host prediction tool for plasmid contigs using Transformer.
Hey there,
Thanks for developing this software.
I bumped into some issues here:
There is nothing wrong when I run the example data.
But, when I try mine (~ 450 MB after pretreatment by preprocessing.py), the pipeline reported error below. Could you please help me out? I guess somewhere in the HOTSPOT.py uses gpu? is it possible to not use it?
Identifying classes in Bacteria ...
76793 plasmid contigs to be predicted ...
Traceback (most recent call last):
File "/home/disk1/HOTSPOT/HOTSPOT.py", line 181, in
logit, _ = model(sentence)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1130, in _c all_impl
return forward_call(*input, **kwargs)
File "/home/disk1/HOTSPOT/library/model.py", line 210, in forward
feat1 = self.Trans1(sentence1)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1130, in _c all_impl
return forward_call(*input, **kwargs)
File "/home/disk1/HOTSPOT/library/model.py", line 170, in forward
enc_src = self.encoder(src, src_mask)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1130, in _c all_impl
return forward_call(*input, **kwargs)
File "/home/disk1/HOTSPOT/library/model.py", line 127, in forward
out = self.layers(out, out, out, mask)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1130, in _c all_impl
return forward_call(*input, **kwargs)
File "/home/disk1/HOTSPOT/library/model.py", line 84, in forward
attention = self.attention(value, key, query, mask)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1130, in _c all_impl
return forward_call(*input, **kwargs)
File "/home/disk1/HOTSPOT/library/model.py", line 39, in forward
energy = torch.einsum("nqhd,nkhd->nhqk", [queries, keys])
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/functional.py", line 358, in einsum
return einsum(equation, *_operands)
File "/home/disk1/Anaconda3/envs/hotspot/lib/python3.8/site-packages/torch/functional.py", line 360, in einsum
return _VF.einsum(equation, operands) # type: ignore[attr-defined]
RuntimeError: CUDA out of memory. Tried to allocate 978.00 MiB (GPU 0; 1.95 GiB total capacity; 898.40 MiB already a llocated; 615.62 MiB free; 938.00 MiB reserved in total by PyTorch) If reserved memory is >> allocated memory try se tting max_split_size_mb to avoid fragmentation. See documentation for Memory Management and PYTORCH_CUDA_ALLOC_CONF
Hi there,
Great work with this tool! I'm testing it right now on my data and just realised that the --threads
parameter in HOTSPOT.py
doesn't work as it should. In my case I set it to 10 and it just defaulted to using all the available threads in the server. Just a heads up as this can generate some problems in the future...
Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.