Skip to content

Commit

Permalink
Add recipe for stripepy-hic (#52945)
Browse files Browse the repository at this point in the history
* Add recipe for stripepy-hic

* Bugfix

* Bugfix

* Bugfix

* Relax pins

* Depend on seaborn-base instead of seaborn

* Skip tests covering plots

Tests are likely failing due to missing/different fonts

* Avoid downloading unnecessary test files

* Suppress warnings issued by pytest
  • Loading branch information
robomics authored Dec 23, 2024
1 parent 907bd9d commit c87ec0e
Show file tree
Hide file tree
Showing 2 changed files with 84 additions and 0 deletions.
63 changes: 63 additions & 0 deletions recipes/stripepy-hic/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{% set name = "stripepy-hic" %}
{% set version = "0.0.2" %}
{% set sha256 = "4e0e14f365334095b9af04874b01bae25fb385560add5f6f0bc91b35f757e556" %}

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://pypi.org/packages/source/{{ name[0] }}/{{ name|replace("-", "_") }}/{{ name|replace("-", "_") }}-{{ version }}.tar.gz
sha256: {{ sha256 }}

build:
number: 0
noarch: python
entry_points:
- stripepy = stripepy:main
script: "{{ PYTHON }} -m pip install . --no-deps --no-build-isolation --no-cache-dir -v"
run_exports:
- {{ pin_subpackage('stripepy-hic', max_pin="x.x") }}

requirements:
host:
- python >=3.9
- pip
- hatchling
- hatch-vcs
run:
- h5py >=3
- hictkpy >=1
- matplotlib-base >=3.8
- numpy
- pandas >=2
- scikit-learn
- scipy
- seaborn-base >=0.13

about:
home: https://github.com/paulsengroup/StripePy
license: MIT
license_file: LICENCE
summary: "StripePy recognizes architectural stripes in 3C and Hi-C contact maps using geometric reasoning"
dev_url: https://github.com/paulsengroup/StripePy
doc_url: https://github.com/paulsengroup/StripePy/blob/main/README.md

test:
requires:
- curl
- perl-digest-md5
- pytest>=8
source_files:
- test/*
imports:
- stripepy

extra:
recipe-maintainers:
- robomics
- rea1991
- jonnings
identifiers:
- biotools:stripepy-hic
- doi:10.5281/zenodo.14394041
21 changes: 21 additions & 0 deletions recipes/stripepy-hic/run_test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env bash

# Download test datasets
mkdir -p test/data

curl -L 'https://zenodo.org/records/14517632/files/4DNFI9GMP2J8.stripepy.mcool?download=1' -o test/data/4DNFI9GMP2J8.mcool
curl -L 'https://zenodo.org/records/14517632/files/results_4DNFI9GMP2J8_v1.hdf5?download=1' -o test/data/results_4DNFI9GMP2J8_v1.hdf5

# Checksum datasets
echo 'a17d08460c03cf6c926e2ca5743e4888 test/data/4DNFI9GMP2J8.mcool' > checksums.md5
echo '632b2a7a6e5c1a24dc3635710ed68a80 test/data/results_4DNFI9GMP2J8_v1.hdf5' >> checksums.md5

md5sum -c checksums.md5

# Test CLI
stripepy --help
stripepy --version

# Run automated test suites
"$PYTHON" -m pytest test/ -m unit -v --disable-pytest-warnings
"$PYTHON" -m pytest test/ -m end2end -v -k 'not TestStripePyPlot' --disable-pytest-warnings

0 comments on commit c87ec0e

Please sign in to comment.