moose-classifier 0.10__tar.gz → 0.12__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: moose_classifier
3
- Version: 0.10
3
+ Version: 0.12
4
4
  Summary: Alignment based taxonomic classifier
5
5
  Author: Chris Rosenthal
6
6
  Author-email: crosenth@gmail.com
@@ -690,6 +690,7 @@ Requires-Python: >=3.7
690
690
  Description-Content-Type: text/markdown
691
691
  License-File: LICENSE
692
692
  Requires-Dist: pandas>=2.0.2
693
+ Dynamic: license-file
693
694
 
694
695
  # moose
695
696
 
@@ -20,7 +20,7 @@ license = {file = "LICENSE"}
20
20
  name = "moose_classifier"
21
21
  readme = "README.md"
22
22
  requires-python = ">=3.7"
23
- version = "0.10"
23
+ version = "0.12"
24
24
 
25
25
  [project.urls]
26
26
  repository = "https://github.com/crosenth/moose"
@@ -132,7 +132,7 @@ import bz2
132
132
  import csv
133
133
  import gzip
134
134
  import itertools
135
- from src import __version__, lineages
135
+ import lineages
136
136
  import logging
137
137
  import lzma
138
138
  import math
@@ -142,6 +142,7 @@ import operator
142
142
  import os
143
143
  import sys
144
144
  import tarfile
145
+ import version
145
146
 
146
147
  ASSIGNMENT_TAX_ID = 'assignment_tax_id'
147
148
 
@@ -411,7 +412,8 @@ def action(args):
411
412
  'threshold_level', 'assignment_level',
412
413
  'threshold_level_threshold', 'assignment_level_threshold']
413
414
  return_cols = ['assignment_threshold', 'best_hit']
414
- best_hits[return_cols] = spec_group[sub_cols].apply(select_best_hits)
415
+ best_hits.loc[:, return_cols] = spec_group[sub_cols].apply(
416
+ select_best_hits)
415
417
  best_hits = best_hits[best_hits['best_hit']]
416
418
 
417
419
  if args.hits_below_threshold:
@@ -505,20 +507,16 @@ def action(args):
505
507
  qseqids['assignment_hash'] = 0
506
508
  qseqids['assignment_tax_name'] = ''
507
509
  qseqids['assignment_rank'] = ''
510
+ qseqids['assignment_rank'] = qseqids['assignment_rank'].astype(cat_ranks)
508
511
  qseqids['assignment_threshold'] = numpy.nan
509
512
  qseqids['condensed_id'] = ''
510
513
  qseqids['condensed_rank'] = ''
514
+ qseqids['condensed_rank'] = qseqids['condensed_rank'].astype(cat_ranks)
511
515
  qseqids['starred'] = ''
512
516
 
513
- if aligns.empty:
514
- dtypes = qseqids.dtypes
515
- else:
516
- dtypes = aligns.dtypes
517
-
518
517
  # add back qseqids that have no hits back into aligns
519
518
  if not qseqids.empty:
520
519
  aligns = pd.concat([aligns, qseqids])
521
- aligns = aligns.astype(dtypes)
522
520
 
523
521
  # concludes our alignment details, on to output summary
524
522
  logging.info('summarizing output')
@@ -713,7 +711,7 @@ def build_parser():
713
711
  package_parser.add_argument(
714
712
  '-V', '--version',
715
713
  action='version',
716
- version=__version__,
714
+ version=version.__version__,
717
715
  help='Print the version number and exit')
718
716
  package_parser.add_argument(
719
717
  '-l', '--log',
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: moose_classifier
3
- Version: 0.10
3
+ Version: 0.12
4
4
  Summary: Alignment based taxonomic classifier
5
5
  Author: Chris Rosenthal
6
6
  Author-email: crosenth@gmail.com
@@ -690,6 +690,7 @@ Requires-Python: >=3.7
690
690
  Description-Content-Type: text/markdown
691
691
  License-File: LICENSE
692
692
  Requires-Dist: pandas>=2.0.2
693
+ Dynamic: license-file
693
694
 
694
695
  # moose
695
696
 
@@ -1,9 +1,9 @@
1
1
  LICENSE
2
2
  README.md
3
3
  pyproject.toml
4
- src/__init__.py
5
4
  src/classify.py
6
5
  src/lineages.py
6
+ src/version.py
7
7
  src/moose_classifier.egg-info/PKG-INFO
8
8
  src/moose_classifier.egg-info/SOURCES.txt
9
9
  src/moose_classifier.egg-info/dependency_links.txt
@@ -1,3 +1,3 @@
1
- __init__
2
1
  classify
3
2
  lineages
3
+ version
@@ -1,6 +1,6 @@
1
1
  from importlib.metadata import PackageNotFoundError, version
2
2
 
3
3
  try:
4
- __version__ = version('moose-classifier')
4
+ __version__ = version('moose-classifier')
5
5
  except PackageNotFoundError:
6
6
  __version__ = ''
@@ -1,7 +1,7 @@
1
1
  """
2
2
  Test classifier
3
3
  """
4
- from src import classify
4
+ import classify
5
5
  import filecmp
6
6
  import logging
7
7
  import os
File without changes