-
Notifications
You must be signed in to change notification settings - Fork 16
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
make cugraph-ops optional for cugraph-gnn packages #99
base: branch-25.02
Are you sure you want to change the base?
Changes from 2 commits
4f4c82e
d3f975a
eddabef
bafd813
a111a09
8e5a0f8
4992680
c48941a
1120cdb
0d285e0
c4019df
be8996f
ec9598e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,7 +20,6 @@ files: | |
- depends_on_dask_cudf | ||
- depends_on_pylibraft | ||
- depends_on_raft_dask | ||
- depends_on_pylibcugraphops | ||
- depends_on_cupy | ||
- depends_on_pytorch | ||
- depends_on_dgl | ||
|
@@ -45,7 +44,6 @@ files: | |
- cuda_version | ||
- docs | ||
- py_version | ||
- depends_on_pylibcugraphops | ||
test_cpp: | ||
output: none | ||
includes: | ||
|
@@ -116,7 +114,6 @@ files: | |
table: project | ||
includes: | ||
- depends_on_cugraph | ||
- depends_on_pylibcugraphops | ||
- python_run_cugraph_dgl | ||
py_test_cugraph_dgl: | ||
output: pyproject | ||
|
@@ -142,7 +139,6 @@ files: | |
table: project | ||
includes: | ||
- depends_on_cugraph | ||
- depends_on_pylibcugraphops | ||
- depends_on_pyg | ||
- python_run_cugraph_pyg | ||
py_test_cugraph_pyg: | ||
|
@@ -166,7 +162,6 @@ files: | |
includes: | ||
- checks | ||
- depends_on_cugraph | ||
- depends_on_pylibcugraphops | ||
- depends_on_dgl | ||
- depends_on_pytorch | ||
- cugraph_dgl_dev | ||
|
@@ -180,7 +175,6 @@ files: | |
- checks | ||
- depends_on_cugraph | ||
- depends_on_pyg | ||
- depends_on_pylibcugraphops | ||
- depends_on_pytorch | ||
- cugraph_pyg_dev | ||
- test_python_common | ||
|
@@ -406,7 +400,6 @@ dependencies: | |
common: | ||
- output_types: [conda] | ||
packages: | ||
- pytorch>=2.3 | ||
- torchdata | ||
- pydantic | ||
specific: | ||
|
@@ -431,18 +424,16 @@ dependencies: | |
- *tensordict | ||
- {matrix: null, packages: [*pytorch_pip, *tensordict]} | ||
- output_types: [conda] | ||
# PyTorch will stop publishing conda packages after 2.5. | ||
# Consider switching to conda-forge::pytorch-gpu. | ||
# Note that the CUDA version may differ from the official PyTorch wheels. | ||
matrices: | ||
- matrix: {cuda: "12.1"} | ||
packages: | ||
- pytorch-cuda=12.1 | ||
- matrix: {cuda: "12.4"} | ||
- matrix: {cuda: "12.*"} | ||
packages: | ||
- pytorch-cuda=12.4 | ||
- matrix: {cuda: "11.8"} | ||
- pytorch-gpu>=2.3=*cuda120* | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is already using conda-forge, I think? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For compatibility reasons we may want to stick to older builds of pytorch-gpu (built with There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, this PR switches to
Oh, I had not noticed that the most recent build (_306) is only against 12.6. I agree with keeping 12.0 for better backward compatibility. However, the CUDA 11 build seems missing. Do we have details on their build matrix? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. CUDA 11 builds were dropped recently. You may need an older version for CUDA 11 compatibility. I also saw this while working on rapidsai/cudf#17475. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For completeness, the latest CUDA 12.0 build was also 2.5.1 build 303. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Got it, thanks. It shouldn't be a dealbreaker unless another test component ends up requiring a newer version of torch on CUDA 11 down the line. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Note: many CUDA packages, including RAPIDS, are explicitly designed not to have It looks like if we just use CUDA 11 driver present:
shows
CUDA 12 driver present:
shows
No CUDA driver present:
shows
This should be sufficient. Let's try using just There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There are two benefits here, if my proposal above works.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I agree, let's try with That opens up a risk that there may be situations where the solver chooses a CPU-only version because of some conflict, but hopefully
I looked into this today... we shouldn't have needed to specify CUDA versions in build strings for Looks like And the So here in There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @jameslamb These simplifications to drop build string info are only possible now with conda-forge, iirc. I believe more complexity was required when we used the pytorch channel, and we probably just carried that over when switching to conda-forge. |
||
- matrix: {cuda: "11.*"} | ||
packages: | ||
- pytorch-cuda=11.8 | ||
# pytorch only supports certain CUDA versions... skip | ||
# adding pytorch-cuda pinning if any other CUDA version is requested | ||
- pytorch-gpu>=2.3=*cuda118* | ||
- matrix: | ||
packages: | ||
|
||
|
@@ -667,31 +658,6 @@ dependencies: | |
- pylibcugraph-cu11==25.2.*,>=0.0.0a0 | ||
- {matrix: null, packages: [*pylibcugraph_unsuffixed]} | ||
|
||
depends_on_pylibcugraphops: | ||
common: | ||
- output_types: conda | ||
packages: | ||
- &pylibcugraphops_unsuffixed pylibcugraphops==25.2.*,>=0.0.0a0 | ||
- output_types: requirements | ||
packages: | ||
# pip recognizes the index as a global option for the requirements.txt file | ||
- --extra-index-url=https://pypi.nvidia.com | ||
- --extra-index-url=https://pypi.anaconda.org/rapidsai-wheels-nightly/simple | ||
specific: | ||
- output_types: [requirements, pyproject] | ||
matrices: | ||
- matrix: | ||
cuda: "12.*" | ||
cuda_suffixed: "true" | ||
packages: | ||
- pylibcugraphops-cu12==25.2.*,>=0.0.0a0 | ||
- matrix: | ||
cuda: "11.*" | ||
cuda_suffixed: "true" | ||
packages: | ||
- pylibcugraphops-cu11==25.2.*,>=0.0.0a0 | ||
- {matrix: null, packages: [*pylibcugraphops_unsuffixed]} | ||
|
||
depends_on_cupy: | ||
common: | ||
- output_types: conda | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,18 +11,30 @@ | |
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
from .gat_conv import GATConv | ||
from .gatv2_conv import GATv2Conv | ||
from .hetero_gat_conv import HeteroGATConv | ||
from .rgcn_conv import RGCNConv | ||
from .sage_conv import SAGEConv | ||
from .transformer_conv import TransformerConv | ||
import warnings | ||
|
||
__all__ = [ | ||
"GATConv", | ||
"GATv2Conv", | ||
"HeteroGATConv", | ||
"RGCNConv", | ||
"SAGEConv", | ||
"TransformerConv", | ||
] | ||
HAVE_CUGRAPH_OPS = False | ||
try: | ||
import pylibcugraphops | ||
HAVE_CUGRAPH_OPS = True | ||
except ImportError: | ||
pass | ||
except Exception as e: | ||
warnings.warn(f"Unexpected error while importing pylibcugraphops: {e}") | ||
|
||
if HAVE_CUGRAPH_OPS: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is this PR putting cugraph-ops stuff behind a conditional import instead of completely removing it? Or, said another way.... how are you expecting that someone would have I'm hoping we can completely stop publishing There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The conditional import is there because we planned to migrate cugraph-ops to a new location, and the new package will possibly retain the same name. We understand that rapids won't release cugraph-ops in 25.02. It's more of a placeholder for the migrated package. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh interesting, did not know that! Ok thank you. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since this new home for the code doesn't exist yet, can we remove the warning on line 24? It seems wrong to warn about something you know does not exist. |
||
from .gat_conv import GATConv | ||
from .gatv2_conv import GATv2Conv | ||
from .hetero_gat_conv import HeteroGATConv | ||
from .rgcn_conv import RGCNConv | ||
from .sage_conv import SAGEConv | ||
from .transformer_conv import TransformerConv | ||
|
||
__all__ = [ | ||
"GATConv", | ||
"GATv2Conv", | ||
"HeteroGATConv", | ||
"RGCNConv", | ||
"SAGEConv", | ||
"TransformerConv", | ||
] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can the dependencies in the conda recipes be removed as well?
cugraph-gnn/conda/recipes/cugraph-pyg/meta.yaml
Line 38 in 71675d8
cugraph-gnn/conda/recipes/cugraph-dgl/meta.yaml
Line 32 in 71675d8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tingyu66 could you please make this change (removing the dependencies on
pylibcugraphops
in conda recipes) in this PR?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jameslamb Done, thank you!