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

DOC: Show very simple usage and benchmark against continuum/miniconda3 #488

Open
corneliusroemer opened this issue Jun 3, 2024 · 2 comments

Comments

@corneliusroemer
Copy link

I was asked why I prefer micromamba-docker over continuum/miniconda3.

Miniconda shows this very simple command on their readme, i love it:

docker run -i -t -p 8888:8888 continuumio/miniconda3 /bin/bash -c "\
    conda install jupyter -y --quiet && \
    mkdir -p /opt/notebooks && \
    jupyter notebook \
    --notebook-dir=/opt/notebooks --ip='*' --port=8888 \
    --no-browser --allow-root"

No need for dockerfile, just run this snippet.

Among the advantages for micromamba are:

  • much smaller image
  • wide variety of base images (alpine, ubuntu, cuda, ...)
  • no annoying default base environment
  • no annoying default channels

I tested speed, and indeed it is! I think you could add this to the docs to show a) how simple it is to use the container, and b) that it is more performant than miniconda

Micromamba:

docker run -i -t mambaorg/micromamba /bin/bash -c "\
    time micromamba install -yn base -c bioconda -c conda-forge python=3.10 nextclade -y --quiet && bash"

real    0m9.570s
user    0m9.574s
sys     0m3.865s
docker run -i -t -p 8888:8888 continuumio/miniconda3 /bin/bash -c "\
    time conda install -yn base -c bioconda -c conda-forge python=3.10 nextclade -y --quiet && bash"

real    0m22.089s
user    0m14.953s
sys     0m3.726s

In addition this, the pull time is of course much shorter for micromamba (20 seconds for miniconda on 100Mbps, vs 3 seconds for micromamba)

@corneliusroemer corneliusroemer changed the title DOC: Show very simple usage DOC: Show very simple usage and benchmark against continuum/miniconda3 Jun 3, 2024
@wholtz
Copy link
Member

wholtz commented Jun 3, 2024

Yes, we could do a better job of showing the performance advantages. Would you be up for making a documentation pull request?

@corneliusroemer
Copy link
Author

I'm really sorry but I'm already procrastinating too much 🙃 I can't commit to doing it, happy for you to reuse whatever I've written above without need to attribute (other than mention in PR)

Here's the jupyter example translated to work with micromamba-docker:

docker run -i -t -p 8888:8888 mambaorg/micromamba /bin/bash -c "\
    micromamba install jupyter -n base -y --quiet -c conda-forge&& \
    mkdir -p notebooks && \ 
    jupyter notebook \
    --notebook-dir=notebooks --ip='*' --port=8888 \
    --no-browser --allow-root"

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

No branches or pull requests

2 participants