Closed Xinpeng021001 closed 1 year ago
Hello @Xinpeng021001 Thanks for reporting this bug. Sorry that I didn't get to it until now. I just fixed it in #118 . It was a compatibility issue with newer versions of Pandas. You can update HGTector with:
pip install --force-reinstall --no-cache-dir git+https://github.com/qiyunlab/HGTector.git
Then the problem should be solved. Please let me know if that works for you. Thanks!
Hi! I meet an error when I create the default database and I'm a little confused about it.
(hgtector) [xinpeng@login.crane HGT_db]$ hgtector database --output . --cats microbe --sample 1 --rank species_latin --above --reference --represent --typemater --compile diamond Database building started at 2023-04-11 11:29:00.463394. Downloading NCBI taxonomy database... done. Reading NCBI taxonomy database... done. Total number of TaxIDs: 2499669. Downloading RefSeq assembly summary... done. Reading RefSeq assembly summary... done. Total number of genomes: 296881. Genome categories: archaea, bacteria, fungi, protozoa Downloading genome list per RefSeq category... archaea: 1458 bacteria: 281524 fungi: 496 protozoa: 96 Done. Total number of genomes in categories: 283574. Filtering genomes... Traceback (most recent call last): File "/home/yinlab/xinpeng/.conda/envs/hgtector/bin/hgtector", line 96, in
main()
File "/home/yinlab/xinpeng/.conda/envs/hgtector/bin/hgtector", line 35, in main
module(args)
File "/home/yinlab/xinpeng/.conda/envs/hgtector/lib/python3.11/site-packages/hgtector/database.py", line 134, in call
self.filter_genomes()
File "/home/yinlab/xinpeng/.conda/envs/hgtector/lib/python3.11/site-packages/hgtector/database.py", line 394, in filter_genomes
self.df['accnov'] = self.df['accession'].str.split('.', 1).str[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/yinlab/xinpeng/.conda/envs/hgtector/lib/python3.11/site-packages/pandas/core/strings/accessor.py", line 128, in wrapper
return func(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: StringMethods.split() takes from 1 to 2 positional arguments but 3 were given
Also I used the hgtector database -o HGT_dir --default but same error.