Skip to content

Commit

Permalink
Warn if no input for sprm-to-anndata (#88)
Browse files Browse the repository at this point in the history
* Warn if no input for sprm-to-anndata

* Try using HuBMAP's cwltool

* Try 3.8

Co-authored-by: ilan-gold <[email protected]>
  • Loading branch information
mccalluc and ilan-gold authored Apr 15, 2022
1 parent fb94da7 commit 6d88b87
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ services:
- docker
language: python
python:
- "3.7"
- "3.8"
cache: pip
script:
- ./test.sh
2 changes: 1 addition & 1 deletion containers/sprm-to-anndata/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.0.8
0.0.9
6 changes: 5 additions & 1 deletion containers/sprm-to-anndata/context/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,11 @@ def sprm_to_anndata(img_name, input_dir, output_dir):
def main(input_dir, output_dir):
output_dir.mkdir(exist_ok=True)
# Get all img names by looking for input files of one type.
for input_file in input_dir.glob(f"*{POLYGON_FILE_SUFFUX}"):
glob = f"*{POLYGON_FILE_SUFFUX}"
input_files = list(input_dir.glob(glob))
if not input_files:
raise Exception(f'No matches for {glob} in {input_dir}')
for input_file in input_files:
img_name = Path(input_file).name.split(".")[0]
sprm_to_anndata(img_name, input_dir, output_dir)

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# The runner exposes the CLI and the tool is the actual software.
cwlref-runner==1.0
cwltool==1.0.20190831161204
git+https://github.com/hubmapconsortium/cwltool.git@docker-gpu#egg=cwltool

0 comments on commit 6d88b87

Please sign in to comment.