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

avamb snakemake pipeline error in run_vamb #200

Closed
SebastianDall opened this issue Sep 12, 2023 · 2 comments · Fixed by #201
Closed

avamb snakemake pipeline error in run_vamb #200

SebastianDall opened this issue Sep 12, 2023 · 2 comments · Fixed by #201

Comments

@SebastianDall
Copy link

Hello Jakob

I am having trouble running the avamb snakemake pipeline.

Firstly, I had an issue in the bam_abundance rule where I received a "missing positional argument" in the py_runcoverm from parsebam.py. I fixed it (I hope) by supplying none as default. I have made a pull request, since the pipeline continued after this change.

However in the next rule run_vamb I received another error:

Traceback (most recent call last):
  File ".conda/envs/avamb/bin/vamb", line 33, in <module>
    sys.exit(load_entry_point('vamb', 'console_scripts', 'vamb')())
  File "vamb/vamb/__main__.py", line 1390, in main
    run(
  File "vamb/vamb/__main__.py", line 831, in run
    cluster(
  File "vamb/vamb/__main__.py", line 637, in cluster
    cluster_generator = vamb.cluster.ClusterGenerator(
TypeError: __init__() got an unexpected keyword argument 'seed'

I tried to run the rule manually with the same result:

(avamb) vamb --outdir avamb_outdir/avamb --fasta avamb_outdir/contigs.flt.fna.gz -p 20 --rpkm avamb_outdir/abundance.npz -m 2000 --minfasta 200000    --model vae-aae  -o C  --seed 0

I looked at the vamb.cluster.ClusterGenerator source code and couldn't find a seed argument, so I commented it out:

cluster_generator = vamb.cluster.ClusterGenerator(
        latent,
        windowsize=cluster_options.window_size,
        minsuccesses=cluster_options.min_successes,
        destroy=True,
        normalized=False,
        cuda=vamb_options.cuda,
        # seed=vamb_options.seed,
    )

And tried running it again. The next error was:

Traceback (most recent call last):
  File ".conda/envs/avamb/bin/vamb", line 33, in <module>
    sys.exit(load_entry_point('vamb', 'console_scripts', 'vamb')())
  File "vamb/vamb/__main__.py", line 1390, in main
    run(
  File "vamb/vamb/__main__.py", line 831, in run
    cluster(
  File "vamb/vamb/__main__.py", line 637, in cluster
    cluster_generator = vamb.cluster.ClusterGenerator(
TypeError: __init__() missing 1 required positional argument: 'lengths'

At this point I am lost. I can see a file in avamb_outdir/avamb/lengths.npz, but I am unsure what to do with it.

I have tried on both my own samples and the example data with the same result. I have also tried reinstalling everything. I could use some help please.

Best,
Sebastian

@jakobnissen
Copy link
Member

Dear @SebastianDall

Thanks for the bug report. This is fixed in #201, which will be merged shortly.

@jakobnissen jakobnissen linked a pull request Sep 12, 2023 that will close this issue
@SebastianDall
Copy link
Author

Awesome! Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants