[R] Use new interface for creating DMatrix from CSR. (#8455)

* [R] Use new interface for creating DMatrix from CSR.

- CSC is still using the old API.

The old API is not aware of `nthread` parameter, which makes DMatrix to use all available
thread during construction and during transformation lie `SparsePage` -> `CSCPage`.
This commit is contained in:
Jiaming Yuan
2022-11-23 21:36:43 +08:00
committed by GitHub
parent 58d211545f
commit 5f1a6fca0d
6 changed files with 68 additions and 33 deletions

View File

@@ -165,7 +165,10 @@ def check_rmarkdown() -> None:
subprocess.check_call([rscript, "-e", "devtools::document()"], env=env)
output = subprocess.run(["git", "diff", "--name-only"], capture_output=True)
if len(output.stdout.decode("utf-8").strip()) != 0:
raise ValueError("Please run `devtools::document()`.")
output = subprocess.run(["git", "diff"], capture_output=True)
raise ValueError(
"Please run `devtools::document()`. Diff:\n", output.stdout.decode("utf-8")
)
@cd(r_package)