Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Finalise 0.7 release #87

Merged
merged 4 commits into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Anglerfish

[![Anglerfish CI Status](https://github.com/remiolsen/anglerfish/workflows/Anglerfish/badge.svg)](https://github.com/remiolsen/anglerfish/actions)
[![Anglerfish CI Status](https://github.com/NationalGenomicsInfrastructure/anglerfish/workflows/Anglerfish/badge.svg)](https://github.com/NationalGenomicsInfrastructure/anglerfish/actions)
[![PyPI](https://img.shields.io/pypi/v/bio-anglerfish)](https://pypi.python.org/pypi/bio-anglerfish/)
[![Conda (channel only)](https://img.shields.io/conda/vn/bioconda/anglerfish)](https://anaconda.org/bioconda/anglerfish)
[![Docker Container available](https://img.shields.io/docker/automated/remiolsen/anglerfish.svg)](https://hub.docker.com/r/remiolsen/anglerfish/)
Expand Down Expand Up @@ -30,7 +30,7 @@ conda install -c bioconda anglerfish
### Install development version

```
pip install --upgrade --force-reinstall git+https://github.com/remiolsen/anglerfish.git
pip install --upgrade --force-reinstall git+https://github.com/NationalGenomicsInfrastructure/anglerfish.git
```

### For Arm64 processors (e.g. Apple M2)
Expand All @@ -53,7 +53,7 @@ Additionaly, if Docker is your cup of tea, the Dockerfile supplied in this repos
For x86 processors (e.g. Intel/AMD):

```
git clone https://github.com/remiolsen/anglerfish.git
git clone https://github.com/NationalGenomicsInfrastructure/anglerfish.git
cd anglerfish
# Create a the anglerfish conda environment
conda env create -f environment.yml
Expand All @@ -65,7 +65,7 @@ pip install -e ".[dev]"
For Arm64 processors (e.g. Apple M1/M2). First [compile and install minimap2 manually](https://github.com/lh3/minimap2?tab=readme-ov-file#installation), then:

```
git clone https://github.com/remiolsen/anglerfish.git
git clone https://github.com/NationalGenomicsInfrastructure/anglerfish.git
cd anglerfish
# Create a the anglerfish conda environment (but remove minimap2)
conda env create -f <(grep -v minimap2 environment.yml)
Expand Down
6 changes: 4 additions & 2 deletions anglerfish/anglerfish.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ def run_demux(args):
closest_sample = min(sample_dists, key=lambda x: x[0])
# If the distance is more than half the index length, we remove it
if closest_sample[0] >= (len(i[0]) / 2) + 1:
closest_sample = (closest_sample[0], None)
top_unknowns.append([i[0], i[1], None])
else:
# We might have two samples with the same distance
all_min = [
Expand All @@ -297,7 +297,9 @@ def run_demux(args):
if all_min:
closest_sample = (closest_sample[0], ";".join(all_min))

top_unknowns.append([i[0], i[1], closest_sample[1]])
top_unknowns.append(
[i[0], i[1], f"{closest_sample[1]} ({closest_sample[0]})"]
)
report.add_unmatched_stat(top_unknowns, ont_barcode, adaptor_name)

# Check if there were samples in the samplesheet without adaptor alignments and add them to report
Expand Down
4 changes: 2 additions & 2 deletions anglerfish/demux/adaptor.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import importlib
import importlib.resources as resources
import os
import re

Expand Down Expand Up @@ -247,7 +247,7 @@ def load_adaptors(raw: bool = False) -> list[Adaptor] | dict:
"""

# Load adaptors from config file
adaptors_config_path = importlib.resources.files("anglerfish.config").joinpath(
adaptors_config_path = resources.files("anglerfish.config").joinpath(
"adaptors.yaml"
)
assert isinstance(adaptors_config_path, os.PathLike)
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
this_directory = Path(__file__).parent
long_description = (this_directory / "README.md").read_text()

version = "0.7.0dev0"
version = "0.7.0"

setup(
name="bio-anglerfish",
Expand All @@ -28,7 +28,7 @@
long_description_content_type="text/markdown",
author="Remi-Andre Olsen",
author_email="[email protected]",
url="https://github.com/remiolsen/anglerfish",
url="https://github.com/NationalGenomicsInfrastructure/anglerfish",
license="MIT",
python_requires=">=3.12",
packages=find_packages(),
Expand Down
Loading