Skip to content

Commit

Permalink
Merge pull request #224 from pachterlab/devel
Browse files Browse the repository at this point in the history
Release version 0.27.3 → 0.28.0
  • Loading branch information
Yenaled authored Nov 22, 2023
2 parents 14a18ef + 179a089 commit 34396d5
Show file tree
Hide file tree
Showing 36 changed files with 7,147 additions and 4,860 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on: [push]
jobs:
check-code:
name: Check code quality
runs-on: ubuntu-18.04
runs-on: ubuntu-latest
steps:
- name: Checkout branch
uses: actions/checkout@master
Expand All @@ -19,10 +19,10 @@ jobs:
- name: Check code quality
run: make check
build:
runs-on: ubuntu-18.04
runs-on: ubuntu-latest
strategy:
matrix:
python: [3.6, 3.7, 3.8, 3.9 ]
python: [3.7, 3.8, 3.9 ]
os: [ubuntu-20.04]
name: Test on Python ${{ matrix.python }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
jobs:
release-to-pypi:
name: Release to Pypi
runs-on: ubuntu-18.04
runs-on: ubuntu-latest
steps:
- name: Checkout branch
uses: actions/checkout@master
Expand Down
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ instance/
# Scrapy stuff:
.scrapy

# Mac stuff:
.DS_Store

# Sphinx documentation
docs/_build/
docs/api/
Expand Down Expand Up @@ -104,4 +107,5 @@ venv.bak/
# mypy
.mypy_cache/
.DS_Store
.vscode/
.vscode/
.Rhistory
16 changes: 10 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# kb-python
![github version](https://img.shields.io/badge/Version-0.27.3-informational)
[![pypi version](https://img.shields.io/pypi/v/kb-python)](https://pypi.org/project/kb-python/0.27.3/)
![github version](https://img.shields.io/badge/Version-0.28.0-informational)
[![pypi version](https://img.shields.io/pypi/v/kb-python)](https://pypi.org/project/kb-python/0.28.0/)
![python versions](https://img.shields.io/pypi/pyversions/kb_python)
![status](https://github.com/pachterlab/kb_python/workflows/CI/badge.svg)
[![codecov](https://codecov.io/gh/pachterlab/kb_python/branch/master/graph/badge.svg)](https://codecov.io/gh/pachterlab/kb_python)
Expand Down Expand Up @@ -59,10 +59,14 @@ kb ref -i index.idx -g t2g.txt -f1 transcriptome.fa <GENOME> <GENOME_ANNOTATION>
- For example, the zebrafish genome annotation file is hosted by [ensembl](https://uswest.ensembl.org/Danio_rerio/Info/Index) and can be downloaded [here](http://ftp.ensembl.org/pub/release-107/gtf/danio_rerio/Danio_rerio.GRCz11.107.gtf.gz)
- **Note:** The latest genome annotation and genome file for every species on ensembl can be found with the [`gget`](https://github.com/pachterlab/gget) command-line tool.

Prebuilt indices are available at https://github.com/pachterlab/kallisto-transcriptome-indices

#### Examples
```bash
# Index the zebrafish transcriptome genome.fa.gz annotation.gtf.gz
# Index the transcriptome from genome FASTA (genome.fa.gz) and GTF (annotation.gtf.gz)
$ kb ref -i index.idx -g t2g.txt -f1 transcriptome.fa genome.fa.gz annotation.gtf.gz
# An example for downloading a prebuilt reference for mouse
$ kb ref -d mouse -i index.idx -g t2g.txt
```
---
### `kb count`: pseudoalign and count reads
Expand Down Expand Up @@ -93,9 +97,9 @@ The `kb info` command prints out package information including the version of `k

```bash
$ kb info
kb_python 0.27.3 ...
kallisto: 0.48.0 ...
bustools: 0.41.0 ...
kb_python 0.28.0 ...
kallisto: 0.50.1 ...
bustools: 0.43.1 ...
...
```
---
Expand Down
2 changes: 1 addition & 1 deletion dev-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ sphinx>=3.3.1
sphinx-autoapi>=1.5.1
sphinx_rtd_theme>=0.5.0
twine>=2.0.0
wheel==0.34.2
wheel==0.38.1
yapf==0.30.0
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
author = 'Kyung Hoi (Joseph) Min'

# The full version, including alpha/beta/rc tags
release = '0.27.3'
release = '0.28.0'
master_doc = 'index'

# -- General configuration ---------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Welcome to kb-python's documentation!
=====================================

This page contains **DEVELOPER** documentation for ``kb-python`` version ``0.27.3``.
This page contains **DEVELOPER** documentation for ``kb-python`` version ``0.28.0``.
For user documentation and tutorials, please go to `kallisto | bustools <https://www.kallistobus.tools/>`_.

Development Prerequisites
Expand Down
2 changes: 1 addition & 1 deletion kb_python/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.27.3'
__version__ = '0.28.0'
Binary file modified kb_python/bins/darwin/bustools/bustools
Binary file not shown.
Binary file modified kb_python/bins/darwin/kallisto/kallisto
Binary file not shown.
25 changes: 25 additions & 0 deletions kb_python/bins/darwin/m1/bustools/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
BSD 2-Clause License

Copyright (c) 2018, BUStools
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Binary file added kb_python/bins/darwin/m1/bustools/bustools
Binary file not shown.
Binary file added kb_python/bins/darwin/m1/kallisto/kallisto
Binary file not shown.
25 changes: 25 additions & 0 deletions kb_python/bins/darwin/m1/kallisto/license.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
BSD 2-Clause License

Copyright (c) 2017, Nicolas Bray, Harold Pimentel, Páll Melsted and Lior Pachter
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Binary file modified kb_python/bins/linux/bustools/bustools
Binary file not shown.
Binary file modified kb_python/bins/linux/kallisto/kallisto
Binary file not shown.
Empty file modified kb_python/bins/linux/kallisto/license.txt
100644 → 100755
Empty file.
Binary file modified kb_python/bins/windows/bustools/bustools.exe
Binary file not shown.
Binary file modified kb_python/bins/windows/kallisto/kallisto.exe
Binary file not shown.
10 changes: 8 additions & 2 deletions kb_python/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@

PACKAGE_PATH = os.path.abspath(os.path.dirname(__file__))
PLATFORM = platform.system().lower()
CPU = ''
if PLATFORM == 'darwin' and platform.processor().lower() == 'arm':
CPU = 'm1'
BINS_DIR = os.path.join(PACKAGE_PATH, 'bins')
COMPILED_DIR = os.path.join(BINS_DIR, 'compiled')

Expand All @@ -32,7 +35,7 @@ def get_provided_kallisto_path() -> Optional[str]:
Path to the binary, `None` if not found
"""
bin_filename = 'kallisto.exe' if PLATFORM == 'windows' else 'kallisto'
path = os.path.join(BINS_DIR, PLATFORM, 'kallisto', bin_filename)
path = os.path.join(BINS_DIR, PLATFORM, CPU, 'kallisto', bin_filename)
if not os.path.isfile(path):
return None
return path
Expand All @@ -45,7 +48,7 @@ def get_provided_bustools_path() -> Optional[str]:
Path to the binary, `None` if not found
"""
bin_filename = 'bustools.exe' if PLATFORM == 'windows' else 'bustools'
path = os.path.join(BINS_DIR, PLATFORM, 'bustools', bin_filename)
path = os.path.join(BINS_DIR, PLATFORM, CPU, 'bustools', bin_filename)
if not os.path.isfile(path):
return None
return path
Expand Down Expand Up @@ -143,6 +146,9 @@ class Technology(NamedTuple):
Technology(
'SMARTSEQ3', 'Smart-seq3', ngs.chemistry.get_chemistry('smartseq3')
),
Technology(
'STORMSEQ', 'STORM-seq', ngs.chemistry.get_chemistry('stormseq')
),
Technology(
'BDWTA', 'BD Rhapsody', ngs.chemistry.get_chemistry('bd rhapsody')
),
Expand Down
7 changes: 7 additions & 0 deletions kb_python/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
BUS_CDNA_PREFIX = 'spliced'
BUS_INTRON_PREFIX = 'unspliced'
ECMAP_FILENAME = 'matrix.ec'
GENE_NAMES_FILENAME = 'genes.names.txt'
TXNAMES_FILENAME = 'transcripts.txt'
KB_INFO_FILENAME = 'kb_info.json'
KALLISTO_INFO_FILENAME = 'run_info.json'
Expand All @@ -31,6 +32,8 @@
GENE_NAME = 'gene'
FEATURE_NAME = 'feature'
TRANSCRIPT_NAME = 'transcript'
GENOMEBAM_FILENAME = 'pseudoalignments.bam'
GENOMEBAM_INDEX_FILENAME = 'pseudoalignments.bam.bai'

UNFILTERED_COUNTS_DIR = 'counts_unfiltered'
FILTERED_COUNTS_DIR = 'counts_filtered'
Expand All @@ -46,6 +49,7 @@
FLENS_FILENAME = 'flens.txt'
BATCH_FILENAME = 'batch.txt'
ABUNDANCE_GENE_FILENAME = 'matrix.abundance.gene.mtx'
ABUNDANCE_GENE_NAMES_FILENAME = 'matrix.abundance.gene.names.mtx'
ABUNDANCE_GENE_TPM_FILENAME = 'matrix.abundance.gene.tpm.mtx'
ABUNDANCE_FILENAME = 'matrix.abundance.mtx'
ABUNDANCE_TPM_FILENAME = 'matrix.abundance.tpm.mtx'
Expand All @@ -71,3 +75,6 @@
FILTERED_CODE = 'filtered'
UNFILTERED_CODE = 'unfiltered'
PROJECT_CODE = 'p'

# Loom
VELOCYTO_LOOM_NAMES = 'CellID,Gene'
Loading

0 comments on commit 34396d5

Please sign in to comment.