-
Notifications
You must be signed in to change notification settings - Fork 325
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
Python Documentation / Conda Versions. #3273
Comments
Great feedback @gattia 👍
|
|
Thanks @gattia you can checkout the repository https://github.com/opensim-org/conda-opensim and follow the instructions on the readme. It's supposed to work out of the box for python 3.7, 3.8, 3.9 but may take a while. Let me know if you run into issues and I'll try to help troubleshoot. The resulting bz2 files can be uploaded to our anaconda.org account then. Thank you. |
@gattia I'm following up on this since Scott Ulrich was having issues using the conda package on osx 12.4 with M1 processor, can you comment on your environment? I also just uploaded conda packages built with python 3.9 to the anconda.org user opensim_admin in case you can try them out. Thank you |
Updating meta.yml for conda build. Related to: opensim-org/opensim-core#3273 Recommended [here](https://docs.conda.io/projects/conda-build/en/latest/resources/define-metadata.html#run) that the numpy version should be specified under the requirements/run section. This is where we specify the requirements for the runtime environment. They also specified something about specifying `--numpy` with `conda-build` if using this syntax - I haven't built recipes before so I'll leave that part for someone else that knows the usual syntax/where/when to call this. I also deleted the build string because I believe that this should be done automatically if you specify a version for requirements/run (but Im not positive on this one). I think that this string should be built by conda-build to have a unique hash that goes after the python version to specify the dependencies etc. and this is how different requirements (e.g., numpy) are specified.
@aymanhab Sorry - I dropped the ball on this and haven't had a chance to update the docs. However, I do think I've figured out the issues here. When you install opensim with conda on mac using: So, if you install this when you are in a python 3.10 environment then it seems to install it, but it fails to actually load in python ( To fix this, you can specify the "build_string" eg: I've specified the python version as well as numpy here because it doesn't seem like conda is picking up the numpy dependency either. This stack overflow explains the above syntax where Im specifying a particular build string. I think the root problem here is that when building the conda package the I haven't made conda recipes before, so I might be missing something else, but this seems to be what's going on to me. I've made a pull request on the recipes repo to make this initial fix: opensim-org/conda-opensim#24 This might also be related to the preference for using the base environment with conda that I mentioned in the initial post. I'll hold off until this is sorted to make a pull request on the docs above about recommendations on where to build. For testing purposes, below is code to create environment and test build for python 3.8 & 3.10. Python 3.9 should work out of the box, but that's just because its downloading that version by default.
|
Ahh, I for some reason just loaded back up the docs and noticed that this was already suggested somewhere - someone beat me to it! I think the root cause is still identified over on my pull request on the recipe. However, it failed because the CONDA_PY and CONDA_NPY weren't quite formatted correctly - they dont have the |
Please re-open if this one isn't actually resolved. |
I went to conda install opensim 4.4 (which is amazing!) and noticed 2 things that I have some feedback/questions about.
In my experience this is actually the opposite of what most people would want to do and what is generally recommended. My understanding/experience is that having many packages installed in base conda can actually slow down conda itself quite considerably - particularly when its trying to solve to install new packages. Mamba helps speed this up - but I think the problem still exists. I've actually wiped my entire conda folder and re-started for exactly this reason. So, it is normally strongly suggested that all new programs/pacakges/projects create a conda environment specific for that project and work from that. I think that conda still cache's all downloaded versions (e.g., python 3.9, opensim 4.4) for use in other environments (even if you install it in a virtual environment and not base).
import opensim
it just gave a package not found error. Looking back it looked like it downloaded a python 3.9 version, but just didn't even try to use it for whatever reason. I then created a python 3.9 environment, conda installed and everything has been working as expected. Not a big issue, but worth noting.The text was updated successfully, but these errors were encountered: