Skip to content

Commit 4df110b

Browse files
bottlerfacebook-github-bot
authored andcommitted
remove fvcore dependency
Summary: This is not actually needed and is causing a conda-forge confusion to do with python_abi - which needs users to have `-c conda-forge` when they install pytorch3d. Reviewed By: patricklabatut Differential Revision: D59587930 fbshipit-source-id: 961ae13a62e1b2b2ce6d8781db38bd97eca69e65
1 parent 51fd114 commit 4df110b

20 files changed

+21
-22
lines changed

INSTALL.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ The core library is written in PyTorch. Several components have underlying imple
1212
- PyTorch 2.0.0, 2.0.1, 2.1.0, 2.1.1, 2.1.2, 2.2.0, 2.2.1, 2.2.2, 2.3.0 or 2.3.1.
1313
- torchvision that matches the PyTorch installation. You can install them together as explained at pytorch.org to make sure of this.
1414
- gcc & g++ ≥ 4.9
15-
- [fvcore](https://github.com/facebookresearch/fvcore)
1615
- [ioPath](https://github.com/facebookresearch/iopath)
1716
- If CUDA is to be used, use a version which is supported by the corresponding pytorch version and at least version 9.2.
1817
- If CUDA older than 11.7 is to be used and you are building from source, the CUB library must be available. We recommend version 1.10.0.
@@ -22,7 +21,7 @@ The runtime dependencies can be installed by running:
2221
conda create -n pytorch3d python=3.9
2322
conda activate pytorch3d
2423
conda install pytorch=1.13.0 torchvision pytorch-cuda=11.6 -c pytorch -c nvidia
25-
conda install -c fvcore -c iopath -c conda-forge fvcore iopath
24+
conda install -c iopath iopath
2625
```
2726

2827
For the CUB build time dependency, which you only need if you have CUDA older than 11.7, if you are using conda, you can continue with
@@ -49,6 +48,7 @@ For developing on top of PyTorch3D or contributing, you will need to run the lin
4948
- tdqm
5049
- jupyter
5150
- imageio
51+
- fvcore
5252
- plotly
5353
- opencv-python
5454

@@ -59,6 +59,7 @@ conda install jupyter
5959
pip install scikit-image matplotlib imageio plotly opencv-python
6060
6161
# Tests/Linting
62+
conda install -c fvcore -c conda-forge fvcore
6263
pip install black usort flake8 flake8-bugbear flake8-comprehensions
6364
```
6465

@@ -97,7 +98,7 @@ version_str="".join([
9798
torch.version.cuda.replace(".",""),
9899
f"_pyt{pyt_version_str}"
99100
])
100-
!pip install fvcore iopath
101+
!pip install iopath
101102
!pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html
102103
```
103104

dev/run_tutorials.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ conda init bash
2323
source ~/.bashrc
2424
conda create -y -n myenv python=3.8 matplotlib ipython ipywidgets nbconvert
2525
conda activate myenv
26-
conda install -y -c fvcore -c iopath -c conda-forge fvcore iopath
26+
conda install -y -c iopath iopath
2727
conda install -y -c pytorch pytorch=1.6.0 cudatoolkit=10.1 torchvision
2828
conda install -y -c pytorch3d-nightly pytorch3d
2929
pip install plotly scikit-image

docs/requirements.txt

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ sphinx_rtd_theme
55
sphinx_markdown_tables
66
numpy
77
iopath
8-
fvcore
98
https://download.pytorch.org/whl/cpu/torchvision-0.15.2%2Bcpu-cp311-cp311-linux_x86_64.whl
109
https://download.pytorch.org/whl/cpu/torch-2.0.1%2Bcpu-cp311-cp311-linux_x86_64.whl
1110
omegaconf

docs/tutorials/bundle_adjustment.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
" torch.version.cuda.replace(\".\",\"\"),\n",
9797
" f\"_pyt{pyt_version_str}\"\n",
9898
" ])\n",
99-
" !pip install fvcore iopath\n",
99+
" !pip install iopath\n",
100100
" if sys.platform.startswith(\"linux\"):\n",
101101
" print(\"Trying to install wheel for PyTorch3D\")\n",
102102
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/camera_position_optimization_with_differentiable_rendering.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@
8383
" torch.version.cuda.replace(\".\",\"\"),\n",
8484
" f\"_pyt{pyt_version_str}\"\n",
8585
" ])\n",
86-
" !pip install fvcore iopath\n",
86+
" !pip install iopath\n",
8787
" if sys.platform.startswith(\"linux\"):\n",
8888
" print(\"Trying to install wheel for PyTorch3D\")\n",
8989
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/dataloaders_ShapeNetCore_R2N2.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
" torch.version.cuda.replace(\".\",\"\"),\n",
5959
" f\"_pyt{pyt_version_str}\"\n",
6060
" ])\n",
61-
" !pip install fvcore iopath\n",
61+
" !pip install iopath\n",
6262
" if sys.platform.startswith(\"linux\"):\n",
6363
" print(\"Trying to install wheel for PyTorch3D\")\n",
6464
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/deform_source_mesh_to_target_mesh.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
" torch.version.cuda.replace(\".\",\"\"),\n",
9898
" f\"_pyt{pyt_version_str}\"\n",
9999
" ])\n",
100-
" !pip install fvcore iopath\n",
100+
" !pip install iopath\n",
101101
" if sys.platform.startswith(\"linux\"):\n",
102102
" print(\"Trying to install wheel for PyTorch3D\")\n",
103103
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/fit_simple_neural_radiance_field.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
" torch.version.cuda.replace(\".\",\"\"),\n",
6464
" f\"_pyt{pyt_version_str}\"\n",
6565
" ])\n",
66-
" !pip install fvcore iopath\n",
66+
" !pip install iopath\n",
6767
" if sys.platform.startswith(\"linux\"):\n",
6868
" print(\"Trying to install wheel for PyTorch3D\")\n",
6969
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/fit_textured_mesh.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
" torch.version.cuda.replace(\".\",\"\"),\n",
7676
" f\"_pyt{pyt_version_str}\"\n",
7777
" ])\n",
78-
" !pip install fvcore iopath\n",
78+
" !pip install iopath\n",
7979
" if sys.platform.startswith(\"linux\"):\n",
8080
" print(\"Trying to install wheel for PyTorch3D\")\n",
8181
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/fit_textured_volume.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
" torch.version.cuda.replace(\".\",\"\"),\n",
5555
" f\"_pyt{pyt_version_str}\"\n",
5656
" ])\n",
57-
" !pip install fvcore iopath\n",
57+
" !pip install iopath\n",
5858
" if sys.platform.startswith(\"linux\"):\n",
5959
" print(\"Trying to install wheel for PyTorch3D\")\n",
6060
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/implicitron_config_system.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@
8585
" torch.version.cuda.replace(\".\",\"\"),\n",
8686
" f\"_pyt{pyt_version_str}\"\n",
8787
" ])\n",
88-
" !pip install fvcore iopath\n",
88+
" !pip install iopath\n",
8989
" if sys.platform.startswith(\"linux\"):\n",
9090
" print(\"Trying to install wheel for PyTorch3D\")\n",
9191
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/implicitron_volumes.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@
7979
" torch.version.cuda.replace(\".\",\"\"),\n",
8080
" f\"_pyt{pyt_version_str}\"\n",
8181
" ])\n",
82-
" !pip install fvcore iopath\n",
82+
" !pip install iopath\n",
8383
" if sys.platform.startswith(\"linux\"):\n",
8484
" print(\"Trying to install wheel for PyTorch3D\")\n",
8585
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/render_colored_points.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
" torch.version.cuda.replace(\".\",\"\"),\n",
5858
" f\"_pyt{pyt_version_str}\"\n",
5959
" ])\n",
60-
" !pip install fvcore iopath\n",
60+
" !pip install iopath\n",
6161
" if sys.platform.startswith(\"linux\"):\n",
6262
" print(\"Trying to install wheel for PyTorch3D\")\n",
6363
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/render_densepose.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
" torch.version.cuda.replace(\".\",\"\"),\n",
6565
" f\"_pyt{pyt_version_str}\"\n",
6666
" ])\n",
67-
" !pip install fvcore iopath\n",
67+
" !pip install iopath\n",
6868
" if sys.platform.startswith(\"linux\"):\n",
6969
" print(\"Trying to install wheel for PyTorch3D\")\n",
7070
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

docs/tutorials/render_textured_meshes.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080
" torch.version.cuda.replace(\".\",\"\"),\n",
8181
" f\"_pyt{pyt_version_str}\"\n",
8282
" ])\n",
83-
" !pip install fvcore iopath\n",
83+
" !pip install iopath\n",
8484
" if sys.platform.startswith(\"linux\"):\n",
8585
" print(\"Trying to install wheel for PyTorch3D\")\n",
8686
" !pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html\n",

packaging/build_conda.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ def do_build(start_args: List[str]):
123123
if test_flag is not None:
124124
args.append(test_flag)
125125

126-
args.extend(["-c", "bottler", "-c", "fvcore", "-c", "iopath", "-c", "conda-forge"])
126+
args.extend(["-c", "bottler", "-c", "iopath", "-c", "conda-forge"])
127127
args.append("--no-anaconda-upload")
128128
args.extend(["--python", os.environ["PYTHON_VERSION"]])
129129
args.append("packaging/pytorch3d")

packaging/linux_wheels/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ version_str="".join([
2626
torch.version.cuda.replace(".",""),
2727
f"_pyt{pyt_version_str}"
2828
])
29-
!pip install fvcore iopath
29+
!pip install iopath
3030
!pip install --no-index --no-cache-dir pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/{version_str}/download.html
3131
```

packaging/linux_wheels/inside.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ do
144144
conda activate "$tag"
145145
# shellcheck disable=SC2086
146146
conda install -y -c pytorch $extra_channel "pytorch=$pytorch_version" "$cudatools=$CUDA_TAG"
147-
pip install fvcore iopath
147+
pip install iopath
148148
echo "python version" "$python_version" "pytorch version" "$pytorch_version" "cuda version" "$cu_version" "tag" "$tag"
149149

150150
rm -rf dist

packaging/pytorch3d/meta.yaml

-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ requirements:
2222
- python
2323
- numpy >=1.11
2424
- torchvision >=0.5
25-
- fvcore
2625
- iopath
2726
{{ environ.get('CONDA_PYTORCH_CONSTRAINT') }}
2827
{{ environ.get('CONDA_CUDATOOLKIT_CONSTRAINT') }}

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ def __init__(self, *args, **kwargs):
153153
)
154154
+ [trainer],
155155
package_dir={trainer: "projects/implicitron_trainer"},
156-
install_requires=["fvcore", "iopath"],
156+
install_requires=["iopath"],
157157
extras_require={
158158
"all": ["matplotlib", "tqdm>4.29.0", "imageio", "ipywidgets"],
159159
"dev": ["flake8", "usort"],

0 commit comments

Comments
 (0)