Skip to content

Navigation Menu

Sign in
Sign up

make 'numpydoc' dependency conda-only #8556

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

Open
jameslamb wants to merge 1 commit into NVIDIA:main
base: main
Choose a base branch
Loading
from jameslamb:numpydoc-tests
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions dependencies.yaml
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,6 @@ dependencies:
- ipython
- ipykernel
- nbsphinx
- numpydoc
- &onnxruntime onnxruntime
- recommonmark
- *scikit_learn
Expand All @@ -525,6 +524,7 @@ dependencies:
- output_types: conda
packages:
- doxygen=1.9.1
- numpydoc
- matplotlib-base
- pip:
- nvidia-sphinx-theme
Expand Down Expand Up @@ -663,8 +663,6 @@ dependencies:
- hypothesis>=6.0,<7
- msgspec
- nltk
# upstream sklearn docstring tests require numpydoc<1.9
- numpydoc<1.9
# 'nvidia-ml-py' provides the 'pynvml' module
- nvidia-ml-py>=12
- *onnxruntime
Expand All @@ -683,6 +681,10 @@ dependencies:
- output_types: conda
packages:
- cuvs==26.10.*,>=0.0.0a0
# upstream sklearn docstring tests require numpydoc<1.9
#
# 'numpydoc' is intentionally conda-only, see https://github.com/NVIDIA/cuml/issues/7710
- numpydoc<1.9
test_python_accel_sklearn:
# Exact pin the sklearn versions used for running upstream sklearn tests
# in cuml.accel. We exact pin here since our xfail list is tightly coupled
Expand Down
1 change: 0 additions & 1 deletion python/cuml/pyproject.toml
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ test = [
"lightgbm",
"msgspec",
"nltk",
"numpydoc<1.9",
"nvidia-ml-py>=12",
"onnxruntime",
"pynndescent",
Expand Down
7 changes: 4 additions & 3 deletions python/cuml/tests/test_base.py
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import inspect

import numpy as np
import numpydoc.docscrape
import pandas as pd
import pylibraft.common.handle
import pytest
Expand Down Expand Up @@ -54,6 +53,8 @@ class that derives from `Base`, We ensure that 1) the base arguments exist
"the base arguments in constructors."
)

numpydoc_docscrape = pytest.importorskip("numpydoc.docscrape")

# To quickly find and replace all instances in the documentation, the below
# regex's may be useful
# output_type: r"^[ ]{4}output_type :.*\n(^(?![ ]{0,4}(?![ ]{4,})).*(\n))+"
Expand All @@ -71,12 +72,12 @@ def get_param_doc(param_doc_obj, name: str):

# Load the base class signature, parse the docstring and pull out params
base_sig = inspect.signature(cuml.Base, follow_wrapped=True)
base_doc = numpydoc.docscrape.NumpyDocString(cuml.Base.__doc__)
base_doc = numpydoc_docscrape.NumpyDocString(cuml.Base.__doc__)
base_doc_params = base_doc["Parameters"]

# Load the current class signature, parse the docstring and pull out params
klass_sig = inspect.signature(klass, follow_wrapped=True)
klass_doc = numpydoc.docscrape.NumpyDocString(klass.__doc__ or "")
klass_doc = numpydoc_docscrape.NumpyDocString(klass.__doc__ or "")
klass_doc_params = klass_doc["Parameters"]

for name, param in base_sig.parameters.items():
Expand Down
Loading

AltStyle によって変換されたページ (->オリジナル) /