wandreopoulos / deeplasmid

12 stars 2 forks source link

No module sklearn in docker container #16

Open matnguyen opened 2 weeks ago

matnguyen commented 2 weeks ago

I'm using the GPU docker container as follows (using singularity) singularity run \ /home/mnguye99/scratch_small/mnguyen/bin/deeplasmid.sif \ deeplasmid.sh test.fasta test, but obtain the error

Deeplasmid - Plasmid finder for microbial genome assemblies.
Running deeplasmid.sh .
This .sh script is meant for running Deeplasmid from the Docker image.
Usage: please specify 2 arguments - the input fasta file and output directory - as follows:
 docker run -it  -v /path/to/input/fasta:/srv/jgi-ml/classifier/dl/in.fasta  -v  /path/to/output/directory:/srv/jgi-ml/classifier/dl/outdir   billandreo/deeplasmid     deeplasmid.sh  in.fasta outdir
Contact person: Bill Andreopoulos, wandreopoulos@lbl.gov
Last maintained: December 22, 2022
Using 20240617_120151 for outdir suffix
('oneHot base, size=', 15, ', sample:')
('base:', 'A', '1-hot:', [1.0, 0.0, 0.0, 0.0])
('base:', 'C', '1-hot:', [0.0, 1.0, 0.0, 0.0])
('base:', 'T', '1-hot:', [0.0, 0.0, 1.0, 0.0])
('base:', 'G', '1-hot:', [0.0, 0.0, 0.0, 1.0])
('all bases :', ['A', 'C', 'B', 'D', 'G', 'H', 'K', 'M', 'N', 'S', 'R', 'T', 'W', 'V', 'Y'])
('use seqLenCut=', 300)
Cannot find test/dlFeatures.20240617_120151, creating as new
cpu_count() = 48

Creating pool with 16 processes

        list1(pool.imap(multiproc_pool, jobs_to_run(1), chunksize=0)):
                2.00271606445e-05 seconds
Job finished with success.
        list2(pool.imap(multiproc_pool, jobs_to_run(1), chunksize=0)):
                3.45607995987 seconds
Status of a done job: Job finished with success.
TOTAL_RUNTIME: 3.48632979393
exiting........
Traceback (most recent call last):
  File "/srv/jgi-ml/classifier/dl/format_predict.py", line 11, in <module>
    from Plotter_Plasmid import Plotter_Plasmid
  File "/srv/jgi-ml/classifier/dl/Plotter_Plasmid.py", line 1, in <module>
    from sklearn.metrics import roc_curve, auc, confusion_matrix
ModuleNotFoundError: No module named 'sklearn'
wandreopoulos commented 2 weeks ago

Hello: This docker container is only tested with Docker, not with Singularity. I do not expect it to work with Singularity. Thanks

On Mon, Jun 17, 2024 at 9:11 AM Matthew Nguyen @.***> wrote:

I'm using the GPU docker container as follows (using singularity) singularity run \ /home/mnguye99/scratch_small/mnguyen/bin/deeplasmid.sif \ deeplasmid.sh test.fasta test, but obtain the error

Deeplasmid - Plasmid finder for microbial genome assemblies. Running deeplasmid.sh . This .sh script is meant for running Deeplasmid from the Docker image. Usage: please specify 2 arguments - the input fasta file and output directory - as follows: docker run -it -v /path/to/input/fasta:/srv/jgi-ml/classifier/dl/in.fasta -v /path/to/output/directory:/srv/jgi-ml/classifier/dl/outdir billandreo/deeplasmid deeplasmid.sh in.fasta outdir Contact person: Bill Andreopoulos, @.*** Last maintained: December 22, 2022 Using 20240617_120151 for outdir suffix ('oneHot base, size=', 15, ', sample:') ('base:', 'A', '1-hot:', [1.0, 0.0, 0.0, 0.0]) ('base:', 'C', '1-hot:', [0.0, 1.0, 0.0, 0.0]) ('base:', 'T', '1-hot:', [0.0, 0.0, 1.0, 0.0]) ('base:', 'G', '1-hot:', [0.0, 0.0, 0.0, 1.0]) ('all bases :', ['A', 'C', 'B', 'D', 'G', 'H', 'K', 'M', 'N', 'S', 'R', 'T', 'W', 'V', 'Y']) ('use seqLenCut=', 300) Cannot find test/dlFeatures.20240617_120151, creating as new cpu_count() = 48

Creating pool with 16 processes

    list1(pool.imap(multiproc_pool, jobs_to_run(1), chunksize=0)):
            2.00271606445e-05 seconds

Job finished with success. list2(pool.imap(multiproc_pool, jobs_to_run(1), chunksize=0)): 3.45607995987 seconds Status of a done job: Job finished with success. TOTAL_RUNTIME: 3.48632979393 exiting........ Traceback (most recent call last): File "/srv/jgi-ml/classifier/dl/format_predict.py", line 11, in from Plotter_Plasmid import Plotter_Plasmid File "/srv/jgi-ml/classifier/dl/Plotter_Plasmid.py", line 1, in from sklearn.metrics import roc_curve, auc, confusion_matrix ModuleNotFoundError: No module named 'sklearn'

— Reply to this email directly, view it on GitHub https://github.com/wandreopoulos/deeplasmid/issues/16, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANGW5PQ6H5SB6W22D5WJATZH4DBPAVCNFSM6AAAAABJOJ5TZGVHI2DSMVQWIX3LMV43ASLTON2WKOZSGM2TONZSGIZTAOI . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Thanks, Bill


William B. Andreopoulos, Ph.D. Joint Genome Institute LBNL