Closed jdblischak closed 2 years ago
@jdblischak Thank you very much, this is extremely helpful.
Splitting the environment is a good idea -- I will get on that.
empyrical-dist was a precursor of what became empiricaldist. It is super obsolete at this point.
And yes, if you can make empiricaldist available from conda-forge, that would be great!
Thank you very much, this is extremely helpful.
It's the least I could do. Thanks for the quick merge!
And yes, if you can make empiricaldist available from conda-forge, that would be great!
I opened a PR https://github.com/conda-forge/staged-recipes/pull/18851 to submit empiricaldist to conda-forge
I really enjoyed reading Think Bayes, and I saw your tweet about conda being slow, so I wanted to help out. Please let me know if you'd like me to make any changes, and feel free to close if it isn't helpful.
Background
The biggest change I made was to ignore the defaults channel with
nodefaults
. At best searching the defaults channel will waste time, and at worst it will pull in defaults packages that are incompatible with conda-forge packages (they are built with different compilers). The only reason to keep defaults in the list is occasionally some packages required for Windows compatibility are only available from defaults (but I confirmed that this wasn't the case).By listing conda-forge first, this channel is always searched first. The fastai channel is then consulted whenever a package can't be found in the conda-forge channel.
Demonstration
I purposely tested on Windows since this is likely a big motivator for using conda in the first place.
mamba
installed the environment in under 5 minutes. And this is worst case scenario since it had to index the channels and download all the packages (ie nothing was cached). And I agree with you thatconda
is unuseable in this situation. I let it spin for ~15 minutes before I just killed it.conda list -n ThinkBayes2
Other ideas
Your environment file is quite large because it includes not only packages to run the example code but also packages to build the book. One idea would be to split this into 2 different files. This way readers of the book would have an easier time creating an environment to try out the code
I noticed that a previous version of your package is available from conda-forge: https://github.com/conda-forge/empyrical-dist-feedstock, but not the currrent version. I can add it to conda-forge if you like. That would save the time of installing from
pip
after the environment is solved