Transfers array data to R and returns it as an R array.
Only in the case of scalars is the result a vector of length 1, as R arrays cannot have 0 dimensions.
Arguments
- x
(
arrayish)
An array-like object.- check
(
logical(1))
IfTRUE, sanity-check the materialized R vector against losing information across the device-to-host boundary, and abort if any problematic value is detected. Forwarded to the backend; for thexlabackend the relevant cases arei32/i64values colliding with theNAbit pattern andui64values>= 2^63wrapping throughbit64::integer64. Seepjrt::as_array.PJRTBuffer()for the full list. Defaults toFALSE. See the "Gotchas" vignette.- ...
Additional arguments passed to methods (unused).
Value
An R array or vector of length 1.
Details
This is implemented via the generic tengen::as_array().