conda-forge / staged-recipes

A place to submit conda recipes before they become fully fledged conda-forge feedstocks
https://conda-forge.org
BSD 3-Clause "New" or "Revised" License
701 stars 4.88k forks source link

Add pytorchrl #26748

Closed jan-janssen closed 3 months ago

jan-janssen commented 3 months ago

Checklist

conda-forge-webservices[bot] commented 3 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipes/pytorchrl) and found it was in an excellent condition.

I do have some suggestions for making it better though...

For recipes/pytorchrl:

jan-janssen commented 3 months ago
Encountered problems while solving:
  - nothing provides requested tensordict >=0.4.0
jan-janssen commented 3 months ago

Waiting for https://github.com/conda-forge/tensordict-feedstock/pull/11

jan-janssen commented 3 months ago
  ERROR (pytorchrl,lib/python3.12/site-packages/torchrl/_torchrl.so): $RPATH/libtorch_python.so not found in packages, sysroot(s) nor the missing_dso_whitelist.
.. is this binary repackaging?
conda-forge-webservices[bot] commented 3 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipes/pytorchrl) and found it was in an excellent condition.

jan-janssen commented 3 months ago

@conda-forge/staged-recipes, ready for review

github-actions[bot] commented 3 months ago

To help direct your pull request to the best reviewers, please mention a topic-specifc team if your recipe matches any of the following: conda-forge/help-c-cpp, conda-forge/help-cdts, conda-forge/help-go, conda-forge/help-java, conda-forge/help-julia, conda-forge/help-nodejs, conda-forge/help-perl, conda-forge/help-python, conda-forge/help-python-c, conda-forge/help-r, conda-forge/help-ruby,or conda-forge/help-rust. Thanks!

jan-janssen commented 3 months ago

@conda-forge/help-python-c

jan-janssen commented 3 months ago

@ocefpaf I tried your suggestion, but this causes the tests to fail:

Warning: rpath /home/conda/staged-recipes/build_artifacts/pytorchrl_1719214381235/_build_env/lib is outside prefix /home/conda/staged-recipes/build_artifacts/pytorchrl_1719214381235/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_p (removing it)
   INFO: sysroot: '/home/conda/staged-recipes/build_artifacts/pytorchrl_1719214381235/_build_env/x86_64-conda-linux-gnu/sysroot/' files: '['usr/share/zoneinfo/zone1970.tab', 'usr/share/zoneinfo/zone.tab', 'usr/share/zoneinfo/tzdata.zi', 'usr/share/zoneinfo/right/Zulu']'
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO lib/libc10.so found in conda-forge/linux-64::libtorch==2.3.1=cpu_mkl_h0bb0d08_100
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO lib/libtorch_cpu.so found in conda-forge/linux-64::libtorch==2.3.1=cpu_mkl_h0bb0d08_100
  ERROR (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): $RPATH/libtorch_python.so not found in packages, sysroot(s) nor the missing_dso_whitelist.
.. is this binary repackaging?
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO lib/libstdc++.so.6 found in conda-forge/linux-64::libstdcxx-ng==13.2.0=hc0a3c3a_13
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO lib/libgcc_s.so.1 found in conda-forge/linux-64::libgcc-ng==13.2.0=h77fa898_13
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO x86_64-conda-linux-gnu/sysroot/lib64/libc.so.6 found in CDT/compiler package conda-forge/noarch::sysroot_linux-64==2.17=h4a8ded7_14
   INFO (pytorchrl,lib/python3.11/site-packages/torchrl/_torchrl.so): Needed DSO x86_64-conda-linux-gnu/sysroot/lib64/ld-linux-x86-64.so.2 found in CDT/compiler package conda-forge/noarch::sysroot_linux-64==2.17=h4a8ded7_14
WARNING (pytorchrl): interpreter (Python) package conda-forge/linux-64::python==3.11.9=hb806964_0_cpython in requirements/run but it is not used (i.e. it is overdepending or perhaps statically linked? If that is what you want then add it to `build/ignore_run_exports`)
WARNING (pytorchrl): run-exports library package conda-forge/linux-64::numpy==2.0.0=py311h1461c94_0 in requirements/run but it is not used (i.e. it is overdepending or perhaps statically linked? If that is what you want then add it to `build/ignore_run_exports`)
WARNING (pytorchrl): run-exports library package conda-forge/linux-64::pytorch==2.3.1=cpu_mkl_py311hcb16b95_100 in requirements/run but it is not used (i.e. it is overdepending or perhaps statically linked? If that is what you want then add it to `build/ignore_run_exports`)

My suggestion would be to revert your suggestion and stay with the previous version. It seem like the usage of environment variables in the meta.yaml file was not successful.

ocefpaf commented 3 months ago

Sorry, it should've been {{ SHLIB_EXT }} instead. But it seems you already figured that out.

jan-janssen commented 3 months ago

@ocefpaf I included your recommendations and the tests passed - can you take another look at this pull request?

jan-janssen commented 3 months ago

@ocefpaf Any update on this pull request?

jan-janssen commented 3 months ago

@isuruf Thanks a lot - this fixed the issue. Can you give me a brief explanation why the default installation location is not suitable?

isuruf commented 3 months ago

Usually all the shared libraries live in $PREFIX/lib for conda-forge, however llbitorch_python.so is in $SP_DIR/torch/lib

jan-janssen commented 3 months ago

@ocefpaf and @isuruf Can this pull request be merged?