Skip to content

Commit

Permalink
Bump version to 4.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jakobnissen committed Apr 21, 2023
1 parent 7cbd36f commit efa3e5a
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 21 deletions.
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# Changelog

## v4.0.2-DEV
## v4.1.0
* Fix typo in output AAE_Z cluster names. They are now called e.g. "aae_z_1"
instead of "aae_z1"
* Clean up the directory structure of Avamb workflow.
* Fix the CheckM2 dependencies to allow CheckM2 to be installed
* Allow the Avamb workflow to be run on Slurm clusters
* Fix issue #161: Mismatched refhash when spaces in FASTA headers
* Allow setting the RNG seed from command line

## v4.0.1
* Fix Random.choice for Tensor on Python 3.11. See issue #148
Expand Down
5 changes: 4 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies = [
# Currently pycoverm does not have binaries for Python > 3.11.
# The dependency resolver, will not error on Python 3.11, but attempt
# to build pycoverm from source, but will not get the deps required for that.
requires-python = "<3.12.*,>=3.9.0"
requires-python = "<3.12,>=3.9.0"
scripts = {vamb = "vamb.__main__:main"}

[metadata]
Expand All @@ -28,3 +28,6 @@ readme = {file = "README.md"}
[build-system]
requires = ["setuptools ~= 63.0", "Cython ~= 0.29"]
build-backend = "setuptools.build_meta"

[tool.ruff]
ignore = ["E501"]
2 changes: 1 addition & 1 deletion test/ci.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def changelog_version(path):
with open(path) as file:
next(file) # header
textline = next(filter(None, map(str.strip, file)))
regex = re.compile(r"## v([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z]+)?)")
regex = re.compile(r"## v([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z]+)?)?")
m = regex.search(textline)
if m is None:
raise ValueError("Could not find version in first non-header line of CHANGELOG")
Expand Down
2 changes: 1 addition & 1 deletion vamb/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
7) Split bins using vamb.vambtools
"""

__version__ = (4, 0, 2, "DEV")
__version__ = (4, 1, 0)

from . import vambtools
from . import parsebam
Expand Down
4 changes: 2 additions & 2 deletions vamb/vambtools.py
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,7 @@ def concatenate_fasta(
Output: None
"""

identifiers: set[str] = set()
for inpathno, inpath in enumerate(inpaths):
try:
Expand All @@ -572,7 +572,7 @@ def concatenate_fasta(
for entry in byte_iterfasta(infile):
if len(entry) < minlength:
continue

if rename:
entry.rename(f"S{inpathno + 1}C{entry.identifier}".encode())

Expand Down
8 changes: 6 additions & 2 deletions workflow_avamb/src/manual_drep_JN.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,11 @@ def compute_to_remove(
parser.add_argument(
"--bins_extension", type=str, default=".fna", help="Extension of the bins "
)
parser.add_argument("--min_bin_size", type=int, help="Min bin length to be considered for dereplication ")
parser.add_argument(
"--min_bin_size",
type=int,
help="Min bin length to be considered for dereplication ",
)

opt = parser.parse_args()
args = vars(parser.parse_args())
Expand All @@ -311,5 +315,5 @@ def compute_to_remove(
min_comp=opt.comp,
max_cont=opt.cont,
bins_extension=opt.bins_extension,
min_bin_size=opt.min_bin_size
min_bin_size=opt.min_bin_size,
)
18 changes: 5 additions & 13 deletions workflow_avamb/src/transfer_contigs_and_aggregate_all_nc_bins.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,35 +338,27 @@ def write_nc_bin_scores(

opt = parser.parse_args()

path_run = (
opt.r
)
path_run = opt.r

path_clusters = (
opt.c
)
path_clusters = opt.c
with open(path_clusters) as file:
cluster_contigs = vamb.vambtools.read_clusters(file)

with open(opt.cs_d) as f:
cluster_scores = json.load(f)

path_clusters_not_r = (
opt.cnr
)
path_clusters_not_r = opt.cnr

with open(path_clusters_not_r) as file:
cluster_not_r_contigs = vamb.vambtools.read_clusters(file)

path_bins_ripped_checkm_quality_report = (
opt.sbr
)
path_bins_ripped_checkm_quality_report = opt.sbr

ripped_bins_scores_ar = np.loadtxt(
path_bins_ripped_checkm_quality_report, dtype=str, skiprows=1, ndmin=2
)

drep_folder = opt.d
drep_folder = opt.d

with open(opt.bp_d) as f:
bin_path = json.load(f)
Expand Down

0 comments on commit efa3e5a

Please sign in to comment.