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

mmcv-recipe v2.0.0 #19

Merged
merged 19 commits into from
May 17, 2023
Merged

Conversation

regro-cf-autotick-bot
Copy link
Contributor

It is very likely that the current package version for this feedstock is out of date.

Checklist before merging this PR:

  • Dependencies have been updated if changed: see upstream
  • Tests have passed
  • Updated license if changed and license_file is packaged

Information about this PR:

  1. Feel free to push to the bot's branch to update this PR if needed.
  2. The bot will almost always only open one PR per version.
  3. The bot will stop issuing PRs if more than 3 version bump PRs generated by the bot are open. If you don't want to package a particular version please close the PR.
  4. If you want these PRs to be merged automatically, make an issue with @conda-forge-admin,please add bot automerge in the title and merge the resulting PR. This command will add our bot automerge feature to your feedstock.
  5. If this PR was opened in error or needs to be updated please add the bot-rerun label to this PR. The bot will close this PR and schedule another one. If you do not have permissions to add this label, you can use the phrase @conda-forge-admin, please rerun bot in a PR comment to have the conda-forge-admin add it for you.

Pending Dependency Version Updates

Here is a list of all the pending dependency version updates for this repo. Please double check all dependencies before merging.

Name Upstream Version Current Version
python-lmdb 1.4.1 Anaconda-Server Badge
torchvision 5009 Anaconda-Server Badge

Dependency Analysis

We couldn't run dependency analysis due to an internal error in the bot. :/ Help is very welcome!

This PR was created by the regro-cf-autotick-bot. The regro-cf-autotick-bot is a service to automatically track the dependency graph, migrate packages, and propose package version updates for conda-forge. Feel free to drop us a line if there are any issues! This PR was generated by https://github.com/regro/cf-scripts/actions/runs/4627542516, please use this URL for debugging.

@conda-forge-webservices
Copy link

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 (recipe) and found it was in an excellent condition.

@weiji14
Copy link
Member

weiji14 commented Apr 6, 2023

Need to add an mmengine conda-forge recipe first. Traceback from build failure at https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=685317&view=logs&j=d0d954b5-f111-5dc4-4d76-03b6c9d0cf7e&t=841356e0-85bb-57d8-dbbc-852e683d1642&l=3858:

import: 'mmcv'
Traceback (most recent call last):
  File "/home/conda/feedstock_root/build_artifacts/mmcv-recipe_1680775144270/test_tmp/run_test.py", line 2, in <module>
    import mmcv
  File "/home/conda/feedstock_root/build_artifacts/mmcv-recipe_1680775144270/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.10/site-packages/mmcv/__init__.py", line 4, in <module>
    from .image import *
  File "/home/conda/feedstock_root/build_artifacts/mmcv-recipe_1680775144270/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.10/site-packages/mmcv/image/__init__.py", line 5, in <module>
    from .geometric import (cutout, imcrop, imflip, imflip_, impad,
  File "/home/conda/feedstock_root/build_artifacts/mmcv-recipe_1680775144270/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.10/site-packages/mmcv/image/geometric.py", line 7, in <module>
    from mmengine.utils import to_2tuple
ModuleNotFoundError: No module named 'mmengine'
Tests failed for mmcv-full-2.0.0-cuda112py310h284aa0d_202.conda - moving package to /home/conda/feedstock_root/build_artifacts/broken
WARNING:conda_build.build:Tests failed for mmcv-full-2.0.0-cuda112py310h284aa0d_202.conda - moving package to /home/conda/feedstock_root/build_artifacts/broken
TESTS FAILED: mmcv-full-2.0.0-cuda112py310h284aa0d_202.conda
##[error]Bash exited with code '1'.
Finishing: Run docker build

Edit: Feedstock for mmengine started at conda-forge/staged-recipes#22496

@weiji14
Copy link
Member

weiji14 commented Apr 10, 2023

So in open-mmlab/mmcv#2235 (mmcv=2.0), they've renamed mmcv-full (this conda-forge recipe) to mmcv (and mmcv is renamed to mmcv-lite, but we don't have mmcv or mmcv-lite in conda-forge anyways). May need to follow guidelines on https://conda-forge.org/docs/orga/guidelines.html#renaming-packages and conda-forge/conda-forge.github.io#179 to rename the conda-forge package?

@weiji14 weiji14 mentioned this pull request Apr 10, 2023
3 tasks
Copy link
Member

@weiji14 weiji14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to conda-forge/conda-forge.github.io#1768 (comment), renaming package on conda-forge is no longer supported. So we'll need to create a new mmcv-feedstock repo and archive this older mmcv-recipe-feedstock repo for mmcv>=2.0.0.

@h-vetinari
Copy link
Member

According to conda-forge/conda-forge.github.io#1768 (comment), renaming package on conda-forge is no longer supported.

You can rename the outputs in this feedstock without a problem.

@weiji14
Copy link
Member

weiji14 commented May 13, 2023

According to conda-forge/conda-forge.github.io#1768 (comment), renaming package on conda-forge is no longer supported.

You can rename the outputs in this feedstock without a problem.

Ok, and that would upload the packages to mmcv instead of mmcv-full? Is there an example of this before? Just that it's unclear from the maintainer docs or conda-forge/conda-forge.github.io#1768 on what's the correct procedure now.

@h-vetinari
Copy link
Member

So in open-mmlab/mmcv#2235 (mmcv=2.0), they've renamed mmcv-full (this conda-forge recipe) to mmcv (and mmcv is renamed to mmcv-lite, but we don't have mmcv or mmcv-lite in conda-forge anyways).

So what you do is you rename the output mmcv-full to mmcv. For the existing users of mmcv-full you can add a compatibility output as follows:

outputs:
  - name: mmcv  # renamed from mmcv-full; unchanged otherwise
    build:
      [...]

  # compatibility output for old naming convention
  - name: mmcv-full
    build:
    requirements:
      host:
        # match ABI-relevant host deps of mmcv to avoid hash collisions between wrappers for different mmcv builds
        - numpy
        - python
        - pytorch
        - pytorch ={{ pytorch }}={{ torch_proc_type }}*
        - {{ pin_subpackage("mmcv", exact=True) }}
      run:
        - {{ pin_subpackage("mmcv", exact=True) }}
    test:
      commands:
        - echo "tested in other outputs"

A further improvement would be to add an output mmcv-lite that corresponds to the upstream situation, and then let (the new) mmcv depend on it (but add more dependencies, bindings, functionality, whatever).

Rename package output from mmcv-full to mmcv, and build from the PyPI tar.gz file instead of the GitHub source tar.gz. Cherry-picked from conda-forge/staged-recipes#22536. Also added LICENSE and LICENSE.md files.
@weiji14
Copy link
Member

weiji14 commented May 15, 2023

@conda-forge-admin, please rerender

conda-forge-webservices[bot] and others added 2 commits May 15, 2023 05:23
@weiji14
Copy link
Member

weiji14 commented May 15, 2023

A further improvement would be to add an output mmcv-lite that corresponds to the upstream situation, and then let (the new) mmcv depend on it (but add more dependencies, bindings, functionality, whatever).

Cool, that sounds like a good plan actually. I'll probably do mmcv(-full) for now, and look into mmcv-lite in a separate PR. I see a way to define multiple sources at https://conda.io/projects/conda-build/en/stable/resources/define-metadata.html#source-from-multiple-sources

See if it fixes `ImportError: cannot import name '_fastCopyAndTranspose' from 'numpy.core._multiarray_umath' (/Users/runner/miniforge3/conda-bld/mmcv-recipe_1684234509266/_build_env/venv/lib/python3.10/site-packages/numpy/core/_multiarray_umath.cpython-310-darwin.so)`
@weiji14
Copy link
Member

weiji14 commented May 16, 2023

Sorry for all the noise. Just trying to start almost from scratch and remove any workarounds (e.g. ignored tests, unnecessary dependencies and settings, etc) that were added over time. Got it so that only the osx_64_python3.9 is failing now (the Python 3.8 and 3.10 ones are passing). Wondering if the failure is a bit random because the last build was failing on osx_64_python3.10. I'm only seeing lots of warnings (?) like this in the log at https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=706571&view=logs&j=a8dee1cf-d17f-5cb0-b53f-4a93dfdbfb0c&t=929f6101-935e-5679-3be5-15b073490bac&l=365080:

  /Users/runner/miniforge3/conda-bld/mmcv-recipe_1684271674217/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeho/lib/python3.9/site-packages/torch/include/c10/util/Optional.h:561:15: warning: builtin __has_trivial_copy is deprecated; use __is_trivially_copyable instead [-Wdeprecated-builtins]
                C10_IS_TRIVIALLY_COPYABLE(U) &&
                ^
  /Users/runner/miniforge3/conda-bld/mmcv-recipe_1684271674217/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeho/lib/python3.9/site-packages/torch/include/c10/macros/Macros.h:437:38: note: expanded from macro 'C10_IS_TRIVIALLY_COPYABLE'
  #define C10_IS_TRIVIALLY_COPYABLE(T) __has_trivial_copy(T)
                                       ^
  /Users/runner/miniforge3/conda-bld/mmcv-recipe_1684271674217/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placeho/lib/python3.9/site-packages/torch/include/c10/core/TensorOptions.h:36:55: note: in instantiation of template class 'c10::optional<c10::Layout>' requested here
  inline Layout layout_or_default(c10::optional<Layout> layout) {

Will try a few more things.

Edit: The build failure does appear to be just something flaky? Re-running those macOS non-CUDA builds seems to work on second try.

@weiji14
Copy link
Member

weiji14 commented May 17, 2023

@conda-forge-admin, please rerender

@github-actions
Copy link
Contributor

Hi! This is the friendly automated conda-forge-webservice.

I tried to rerender for you, but it looks like there was nothing to do.

This message was generated by GitHub actions workflow run https://github.com/conda-forge/mmcv-recipe-feedstock/actions/runs/4998676789.

Copy link
Member

@weiji14 weiji14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Builds are green. Let's see if the mmcv-full to mmcv rename works on merge 🚀

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could probably refine this build script a bit more following updated instructions at https://mmcv.readthedocs.io/en/2.x/get_started/build.html#build-mmcv-from-source. E.g. MMCV_WITH_OPS=1 is now the default as mentioned at open-mmlab/mmcv#2235 (comment), so we could probably remove that line. But will keep things as is for now.

license_family: Apache
license_file: LICENSE
summary: OpenMMLab Computer Vision Foundation
license: Apache-2.0 AND LicenseRef-NVIDIA-License
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added custom license Apache-2.0 and LicenseRef-NVIDIA-License following https://github.com/conda-forge/cfep/blob/main/cfep-16.md. Not sure if the NVIDIA License should be named something else, but let's keep it this way for now.

@weiji14 weiji14 merged commit 9e3fb78 into conda-forge:main May 17, 2023
@weiji14
Copy link
Member

weiji14 commented May 17, 2023

Yep, mmcv=2.0.0 packages are now up at https://anaconda.org/conda-forge/mmcv 🎉 Now mamba install mmcv or conda install mmcv should work 🥳

@weiji14 weiji14 mentioned this pull request May 17, 2023
weiji14 added a commit to regro-cf-autotick-bot/mmdet-feedstock that referenced this pull request May 17, 2023
weiji14 added a commit to conda-forge/mmdet-feedstock that referenced this pull request May 17, 2023
* updated v3.0.0

* Rename mmcv-full to mmcv and add shapely

Xref https://github.com/open-mmlab/mmdetection/blame/v3.0.0/requirements/runtime.txt. Rename from mmcv-full to mmcv after conda-forge/mmcv-recipe-feedstock#19.

---------

Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com>
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

Successfully merging this pull request may close these issues.

3 participants