Skip to main content

tensor

family

Declared in clika_rt/clika_rt_core.h.

Members

NameDescription
clika_rt_tensor_statusmirrors ClikaRT::Tensor::Status; fresh numbering
clika_rt_tensor
tensor_absClikaRT::Tensor::abs <- ClikaRT/compute/tensor.h borrows self
tensor_abs_inplaceClikaRT::Tensor::abs_ <- ClikaRT/compute/tensor.h in-place op borrows self
tensor_addClikaRT::Tensor::add <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_add_inplaceClikaRT::Tensor::add_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_const_data_ptrClikaRT::Tensor::const_data_ptr <- ClikaRT/compute/tensor.h borrows self
tensor_contiguousClikaRT::Tensor::contiguous <- ClikaRT/compute/tensor.h borrows self
tensor_definedClikaRT::Tensor::defined <- ClikaRT/compute/tensor.h borrows self infallible
tensor_deviceClikaRT::Tensor::device <- ClikaRT/compute/tensor.h borrows self infallible
tensor_device_const_data_ptrClikaRT::Tensor::device_const_data_ptr <- ClikaRT/compute/tensor.h borrows self
tensor_device_mutable_data_ptrClikaRT::Tensor::device_mutable_data_ptr <- ClikaRT/compute/tensor.h borrows self
tensor_divClikaRT::Tensor::div <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_div_inplaceClikaRT::Tensor::div_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_dtypeClikaRT::Tensor::dtype <- ClikaRT/compute/tensor.h borrows self infallible
tensor_emptyClikaRT::Tensor::empty <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}
tensor_empty_reservedClikaRT::Tensor::empty_reserved <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}
tensor_from_blob_contiguousClikaRT::Tensor::from_blob <- ClikaRT/compute/tensor.h one form of the overloaded C++ from_blob; the _contiguous suffix names this form deleter is the contract §7 triple: the callback takes userdata first; deleter_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL deleter registers nothing C++ defaults (dropped at this surface): where={}, deleter={}, pinned_for={}
tensor_from_blob_stridedClikaRT::Tensor::from_blob <- ClikaRT/compute/tensor.h one form of the overloaded C++ from_blob; the _strided suffix names this form deleter is the contract §7 triple: the callback takes userdata first; deleter_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL deleter registers nothing C++ defaults (dropped at this surface): where={}, deleter={}, pinned_for={}
tensor_from_dataClikaRT::Tensor::from_data <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}
tensor_fullClikaRT::Tensor::full <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}
tensor_indexClikaRT::Tensor::index <- ClikaRT/compute/tensor.h borrows self index payload; embedded tensors BORROWED (contract §11)
tensor_index_putClikaRT::Tensor::index_put <- ClikaRT/compute/tensor.h borrows self index payload; embedded tensors BORROWED (contract §11) value.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11) C++ defaults (dropped at this surface): accumulate=false
tensor_index_put_inplaceClikaRT::Tensor::index_put_ <- ClikaRT/compute/tensor.h in-place op borrows self index payload; embedded tensors BORROWED (contract §11) value.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11) C++ defaults (dropped at this surface): accumulate=false
tensor_is_alias_ofClikaRT::Tensor::is_alias_of <- ClikaRT/compute/tensor.h borrows self borrows other a rejected argument yields the zero result (infallible surface) infallible
tensor_is_contiguousClikaRT::Tensor::is_contiguous <- ClikaRT/compute/tensor.h borrows self infallible
tensor_is_fakeClikaRT::Tensor::is_fake <- ClikaRT/compute/tensor.h borrows self infallible
tensor_is_pinnedClikaRT::Tensor::is_pinned <- ClikaRT/compute/tensor.h borrows self a rejected argument yields the zero result (infallible surface) infallible C++ defaults (dropped at this surface): peer={}
tensor_is_quantizedClikaRT::Tensor::is_quantized <- ClikaRT/compute/tensor.h borrows self infallible
tensor_is_sameClikaRT::Tensor::is_same <- ClikaRT/compute/tensor.h borrows self borrows other a rejected argument yields the zero result (infallible surface) infallible
tensor_item_f32the one element of a single-element tensor as float; a numel other than 1, or a tensor whose dtype is not this width, is refused
tensor_item_f64the one element of a single-element tensor as double; a numel other than 1, or a tensor whose dtype is not this width, is refused
tensor_item_i32the one element of a single-element tensor as int32_t; a numel other than 1, or a tensor whose dtype is not this width, is refused
tensor_item_i64the one element of a single-element tensor as int64_t; a numel other than 1, or a tensor whose dtype is not this width, is refused
tensor_item_u8the one element of a single-element tensor as uint8_t; a numel other than 1, or a tensor whose dtype is not this width, is refused
tensor_max_allClikaRT::Tensor::max <- ClikaRT/compute/tensor.h one form of the overloaded C++ max; the _all suffix names this form borrows self
tensor_max_dimsClikaRT::Tensor::max <- ClikaRT/compute/tensor.h one form of the overloaded C++ max; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false
tensor_mean_allClikaRT::Tensor::mean <- ClikaRT/compute/tensor.h one form of the overloaded C++ mean; the _all suffix names this form borrows self
tensor_mean_dimsClikaRT::Tensor::mean <- ClikaRT/compute/tensor.h one form of the overloaded C++ mean; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false
tensor_metadata_nbytesClikaRT::Tensor::metadata_nbytes <- ClikaRT/compute/tensor.h borrows self infallible
tensor_metadata_ndimClikaRT::Tensor::metadata_ndim <- ClikaRT/compute/tensor.h borrows self infallible
tensor_metadata_numelClikaRT::Tensor::metadata_numel <- ClikaRT/compute/tensor.h borrows self infallible
tensor_metadata_shapeClikaRT::Tensor::metadata_shape <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_metadata_sizesClikaRT::Tensor::metadata_sizes <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_metadata_stridesClikaRT::Tensor::metadata_strides <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_min_allClikaRT::Tensor::min <- ClikaRT/compute/tensor.h one form of the overloaded C++ min; the _all suffix names this form borrows self
tensor_min_dimsClikaRT::Tensor::min <- ClikaRT/compute/tensor.h one form of the overloaded C++ min; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false
tensor_mulClikaRT::Tensor::mul <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_mul_inplaceClikaRT::Tensor::mul_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_mutable_data_ptrClikaRT::Tensor::mutable_data_ptr <- ClikaRT/compute/tensor.h borrows self
tensor_nbytesClikaRT::Tensor::nbytes <- ClikaRT/compute/tensor.h borrows self
tensor_ndimClikaRT::Tensor::ndim <- ClikaRT/compute/tensor.h borrows self infallible
tensor_ndim_hostClikaRT::Tensor::ndim_host <- ClikaRT/compute/tensor.h borrows self
tensor_negClikaRT::Tensor::neg <- ClikaRT/compute/tensor.h borrows self
tensor_neg_inplaceClikaRT::Tensor::neg_ <- ClikaRT/compute/tensor.h in-place op borrows self
tensor_numelClikaRT::Tensor::numel <- ClikaRT/compute/tensor.h borrows self
tensor_numel_hostClikaRT::Tensor::numel_host <- ClikaRT/compute/tensor.h borrows self
tensor_on_completeClikaRT::Tensor::on_complete <- ClikaRT/compute/tensor.h borrows self callback is the contract §7 triple: the callback takes userdata first; callback_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL callback registers nothing a tensor payload is BORROWED for the call only; retain it to keep it past the callback's return the underlying call is infallible plain void
tensor_onesClikaRT::Tensor::ones <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}
tensor_pin_memoryClikaRT::Tensor::pin_memory <- ClikaRT/compute/tensor.h borrows self
tensor_powClikaRT::Tensor::pow <- ClikaRT/compute/tensor.h borrows self exponent.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_release
tensor_reshapeClikaRT::Tensor::reshape <- ClikaRT/compute/tensor.h borrows self embedded tensors BORROWED (contract §11)
tensor_retain
tensor_shapeClikaRT::Tensor::shape <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_shape_host_allClikaRT::Tensor::shape_host <- ClikaRT/compute/tensor.h one form of the overloaded C++ shape_host; the _all suffix names this form borrows self
tensor_shape_host_dimClikaRT::Tensor::shape_host <- ClikaRT/compute/tensor.h one form of the overloaded C++ shape_host; the _dim suffix names this form borrows self
tensor_sizesClikaRT::Tensor::sizes <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_softmaxClikaRT::Tensor::softmax <- ClikaRT/compute/tensor.h borrows self C++ defaults (dropped at this surface): dim=-1
tensor_statusClikaRT::Tensor::status <- ClikaRT/compute/tensor.h borrows self infallible
tensor_streamClikaRT::Tensor::stream <- ClikaRT/compute/tensor.h borrows self infallible; returns an OWNED reference; release when done
tensor_stridesClikaRT::Tensor::strides <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_subClikaRT::Tensor::sub <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_sub_inplaceClikaRT::Tensor::sub_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)
tensor_sum_allClikaRT::Tensor::sum <- ClikaRT/compute/tensor.h one form of the overloaded C++ sum; the _all suffix names this form borrows self
tensor_sum_dimsClikaRT::Tensor::sum <- ClikaRT/compute/tensor.h one form of the overloaded C++ sum; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false
tensor_synchronizeClikaRT::Tensor::synchronize <- ClikaRT/compute/tensor.h borrows self
tensor_to_deviceClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _device suffix names this form borrows self
tensor_to_device_dtypeClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _device_dtype suffix names this form borrows self
tensor_to_dtypeClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _dtype suffix names this form borrows self
tensor_to_stringClikaRT::Tensor::to_string <- ClikaRT/compute/tensor.h borrows self sized-string protocol (contract §5); the status reports BUFFER_TOO_SMALL only
tensor_to_vec_f32every element of a 0-D or 1-D contiguous tensor as float; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_to_vec_f64every element of a 0-D or 1-D contiguous tensor as double; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_to_vec_i32every element of a 0-D or 1-D contiguous tensor as int32_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_to_vec_i64every element of a 0-D or 1-D contiguous tensor as int64_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_to_vec_u8every element of a 0-D or 1-D contiguous tensor as uint8_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)
tensor_zerosClikaRT::Tensor::zeros <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Enumerations

enum clika_rt_tensor_status

enum clika_rt_tensor_status

mirrors ClikaRT::Tensor::Status; fresh numbering

EnumeratorValueDescription
CLIKA_RT_TENSOR_STATUS_UNSCHEDULED0
CLIKA_RT_TENSOR_STATUS_EVALUATED1
CLIKA_RT_TENSOR_STATUS_AVAILABLE2

Declared in clika_rt/clika_rt_core.h, line 250

Type aliases

using clika_rt_tensor

using clika_rt_tensor = struct clika_rt_tensor

Declared in clika_rt/clika_rt_core.h, line 266

Functions

tensor_abs

clika_rt_error*(* tensor_abs)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::abs <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8508

tensor_abs_inplace

clika_rt_error*(* tensor_abs_inplace)(clika_rt_tensor *self)

ClikaRT::Tensor::abs_ <- ClikaRT/compute/tensor.h in-place op borrows self

Declared in clika_rt/clika_rt_core.h, line 8716

tensor_add

clika_rt_error*(* tensor_add)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other, clika_rt_tensor **out)

ClikaRT::Tensor::add <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8583

tensor_add_inplace

clika_rt_error*(* tensor_add_inplace)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other)

ClikaRT::Tensor::add_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8689

tensor_const_data_ptr

clika_rt_error*(* tensor_const_data_ptr)(clika_rt_tensor *self, const void **out)

ClikaRT::Tensor::const_data_ptr <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8445

tensor_contiguous

clika_rt_error*(* tensor_contiguous)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::contiguous <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8434

tensor_defined

uint8_t(* tensor_defined)(clika_rt_tensor *self)

ClikaRT::Tensor::defined <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8298

tensor_device

clika_rt_device(* tensor_device)(clika_rt_tensor *self)

ClikaRT::Tensor::device <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8349

tensor_device_const_data_ptr

clika_rt_error*(* tensor_device_const_data_ptr)(clika_rt_tensor *self, const void **out)

ClikaRT::Tensor::device_const_data_ptr <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8455

tensor_device_mutable_data_ptr

clika_rt_error*(* tensor_device_mutable_data_ptr)(clika_rt_tensor *self, void **out)

ClikaRT::Tensor::device_mutable_data_ptr <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8460

tensor_div

clika_rt_error*(* tensor_div)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other, clika_rt_tensor **out)

ClikaRT::Tensor::div <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8604

tensor_div_inplace

clika_rt_error*(* tensor_div_inplace)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other)

ClikaRT::Tensor::div_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8710

tensor_dtype

clika_rt_data_type(* tensor_dtype)(clika_rt_tensor *self)

ClikaRT::Tensor::dtype <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8344

tensor_empty

clika_rt_error*(* tensor_empty)(const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::empty <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8208

tensor_empty_reserved

clika_rt_error*(* tensor_empty_reserved)(const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_tensor **out)

ClikaRT::Tensor::empty_reserved <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}

Declared in clika_rt/clika_rt_core.h, line 8217

tensor_from_blob_contiguous

clika_rt_error*(* tensor_from_blob_contiguous)(void *data, const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, void(*deleter)(void *userdata, void *p0), void *deleter_userdata, void(*deleter_userdata_free)(void *), clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::from_blob <- ClikaRT/compute/tensor.h one form of the overloaded C++ from_blob; the _contiguous suffix names this form deleter is the contract §7 triple: the callback takes userdata first; deleter_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL deleter registers nothing C++ defaults (dropped at this surface): where={}, deleter={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8266

tensor_from_blob_strided

clika_rt_error*(* tensor_from_blob_strided)(void *data, const int64_t *shape, size_t shape_count, const int64_t *strides, size_t strides_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, void(*deleter)(void *userdata, void *p0), void *deleter_userdata, void(*deleter_userdata_free)(void *), clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::from_blob <- ClikaRT/compute/tensor.h one form of the overloaded C++ from_blob; the _strided suffix names this form deleter is the contract §7 triple: the callback takes userdata first; deleter_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL deleter registers nothing C++ defaults (dropped at this surface): where={}, deleter={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8282

tensor_from_data

clika_rt_error*(* tensor_from_data)(const void *data, const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::from_data <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8253

tensor_full

clika_rt_error*(* tensor_full)(const int64_t *shape, size_t shape_count, double value, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::full <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8243

tensor_index

clika_rt_error*(* tensor_index)(clika_rt_tensor *self, const clika_rt_index_entry *indices, size_t indices_count, clika_rt_tensor **out)

ClikaRT::Tensor::index <- ClikaRT/compute/tensor.h borrows self index payload; embedded tensors BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8656

tensor_index_put

clika_rt_error*(* tensor_index_put)(clika_rt_tensor *self, const clika_rt_index_entry *indices, size_t indices_count, clika_rt_scalar_or_tensor value, uint8_t accumulate, clika_rt_tensor **out)

ClikaRT::Tensor::index_put <- ClikaRT/compute/tensor.h borrows self index payload; embedded tensors BORROWED (contract §11) value.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11) C++ defaults (dropped at this surface): accumulate=false

Declared in clika_rt/clika_rt_core.h, line 8666

tensor_index_put_inplace

clika_rt_error*(* tensor_index_put_inplace)(clika_rt_tensor *self, const clika_rt_index_entry *indices, size_t indices_count, clika_rt_scalar_or_tensor value, uint8_t accumulate)

ClikaRT::Tensor::index_put_ <- ClikaRT/compute/tensor.h in-place op borrows self index payload; embedded tensors BORROWED (contract §11) value.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11) C++ defaults (dropped at this surface): accumulate=false

Declared in clika_rt/clika_rt_core.h, line 8679

tensor_is_alias_of

uint8_t(* tensor_is_alias_of)(clika_rt_tensor *self, clika_rt_tensor *other)

ClikaRT::Tensor::is_alias_of <- ClikaRT/compute/tensor.h borrows self borrows other a rejected argument yields the zero result (infallible surface) infallible

Declared in clika_rt/clika_rt_core.h, line 8496

tensor_is_contiguous

uint8_t(* tensor_is_contiguous)(clika_rt_tensor *self)

ClikaRT::Tensor::is_contiguous <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8359

tensor_is_fake

uint8_t(* tensor_is_fake)(clika_rt_tensor *self)

ClikaRT::Tensor::is_fake <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8372

tensor_is_pinned

uint8_t(* tensor_is_pinned)(clika_rt_tensor *self, clika_rt_stream_or_device peer)

ClikaRT::Tensor::is_pinned <- ClikaRT/compute/tensor.h borrows self a rejected argument yields the zero result (infallible surface) infallible C++ defaults (dropped at this surface): peer={}

Declared in clika_rt/clika_rt_core.h, line 8366

tensor_is_quantized

uint8_t(* tensor_is_quantized)(clika_rt_tensor *self)

ClikaRT::Tensor::is_quantized <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8377

tensor_is_same

uint8_t(* tensor_is_same)(clika_rt_tensor *self, clika_rt_tensor *other)

ClikaRT::Tensor::is_same <- ClikaRT/compute/tensor.h borrows self borrows other a rejected argument yields the zero result (infallible surface) infallible

Declared in clika_rt/clika_rt_core.h, line 8488

tensor_item_f32

clika_rt_error*(* tensor_item_f32)(clika_rt_tensor *self, float *out)

the one element of a single-element tensor as float; a numel other than 1, or a tensor whose dtype is not this width, is refused

Declared in clika_rt/clika_rt_core.h, line 659

tensor_item_f64

clika_rt_error*(* tensor_item_f64)(clika_rt_tensor *self, double *out)

the one element of a single-element tensor as double; a numel other than 1, or a tensor whose dtype is not this width, is refused

Declared in clika_rt/clika_rt_core.h, line 662

tensor_item_i32

clika_rt_error*(* tensor_item_i32)(clika_rt_tensor *self, int32_t *out)

the one element of a single-element tensor as int32_t; a numel other than 1, or a tensor whose dtype is not this width, is refused

Declared in clika_rt/clika_rt_core.h, line 665

tensor_item_i64

clika_rt_error*(* tensor_item_i64)(clika_rt_tensor *self, int64_t *out)

the one element of a single-element tensor as int64_t; a numel other than 1, or a tensor whose dtype is not this width, is refused

Declared in clika_rt/clika_rt_core.h, line 668

tensor_item_u8

clika_rt_error*(* tensor_item_u8)(clika_rt_tensor *self, uint8_t *out)

the one element of a single-element tensor as uint8_t; a numel other than 1, or a tensor whose dtype is not this width, is refused

Declared in clika_rt/clika_rt_core.h, line 671

tensor_max_all

clika_rt_error*(* tensor_max_all)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::max <- ClikaRT/compute/tensor.h one form of the overloaded C++ max; the _all suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8551

tensor_max_dims

clika_rt_error*(* tensor_max_dims)(clika_rt_tensor *self, const int64_t *dims, size_t dims_count, uint8_t keepdim, clika_rt_tensor **out)

ClikaRT::Tensor::max <- ClikaRT/compute/tensor.h one form of the overloaded C++ max; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false

Declared in clika_rt/clika_rt_core.h, line 8558

tensor_mean_all

clika_rt_error*(* tensor_mean_all)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::mean <- ClikaRT/compute/tensor.h one form of the overloaded C++ mean; the _all suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8535

tensor_mean_dims

clika_rt_error*(* tensor_mean_dims)(clika_rt_tensor *self, const int64_t *dims, size_t dims_count, uint8_t keepdim, clika_rt_tensor **out)

ClikaRT::Tensor::mean <- ClikaRT/compute/tensor.h one form of the overloaded C++ mean; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false

Declared in clika_rt/clika_rt_core.h, line 8542

tensor_metadata_nbytes

size_t(* tensor_metadata_nbytes)(clika_rt_tensor *self)

ClikaRT::Tensor::metadata_nbytes <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8339

tensor_metadata_ndim

int64_t(* tensor_metadata_ndim)(clika_rt_tensor *self)

ClikaRT::Tensor::metadata_ndim <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8308

tensor_metadata_numel

int64_t(* tensor_metadata_numel)(clika_rt_tensor *self)

ClikaRT::Tensor::metadata_numel <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8334

tensor_metadata_shape

void(* tensor_metadata_shape)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::metadata_shape <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8313

tensor_metadata_sizes

void(* tensor_metadata_sizes)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::metadata_sizes <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8320

tensor_metadata_strides

void(* tensor_metadata_strides)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::metadata_strides <- ClikaRT/compute/tensor.h borrows self infallible; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8327

tensor_min_all

clika_rt_error*(* tensor_min_all)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::min <- ClikaRT/compute/tensor.h one form of the overloaded C++ min; the _all suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8567

tensor_min_dims

clika_rt_error*(* tensor_min_dims)(clika_rt_tensor *self, const int64_t *dims, size_t dims_count, uint8_t keepdim, clika_rt_tensor **out)

ClikaRT::Tensor::min <- ClikaRT/compute/tensor.h one form of the overloaded C++ min; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false

Declared in clika_rt/clika_rt_core.h, line 8574

tensor_mul

clika_rt_error*(* tensor_mul)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other, clika_rt_tensor **out)

ClikaRT::Tensor::mul <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8597

tensor_mul_inplace

clika_rt_error*(* tensor_mul_inplace)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other)

ClikaRT::Tensor::mul_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8703

tensor_mutable_data_ptr

clika_rt_error*(* tensor_mutable_data_ptr)(clika_rt_tensor *self, void **out)

ClikaRT::Tensor::mutable_data_ptr <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8450

tensor_nbytes

clika_rt_error*(* tensor_nbytes)(clika_rt_tensor *self, size_t *out)

ClikaRT::Tensor::nbytes <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8407

tensor_ndim

int64_t(* tensor_ndim)(clika_rt_tensor *self)

ClikaRT::Tensor::ndim <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8303

tensor_ndim_host

clika_rt_error*(* tensor_ndim_host)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::ndim_host <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8643

tensor_neg

clika_rt_error*(* tensor_neg)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::neg <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8513

tensor_neg_inplace

clika_rt_error*(* tensor_neg_inplace)(clika_rt_tensor *self)

ClikaRT::Tensor::neg_ <- ClikaRT/compute/tensor.h in-place op borrows self

Declared in clika_rt/clika_rt_core.h, line 8721

tensor_numel

clika_rt_error*(* tensor_numel)(clika_rt_tensor *self, int64_t *out)

ClikaRT::Tensor::numel <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8381

tensor_numel_host

clika_rt_error*(* tensor_numel_host)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::numel_host <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8638

tensor_on_complete

clika_rt_error*(* tensor_on_complete)(clika_rt_tensor *self, void(*callback)(void *userdata, clika_rt_tensor *p0), void *callback_userdata, void(*callback_userdata_free)(void *))

ClikaRT::Tensor::on_complete <- ClikaRT/compute/tensor.h borrows self callback is the contract §7 triple: the callback takes userdata first; callback_userdata_free (NULL when no finalizer is needed) runs exactly once when the registration dies, including one that never fires and one whose call the runtime refused at its argument checks a NULL callback registers nothing a tensor payload is BORROWED for the call only; retain it to keep it past the callback's return the underlying call is infallible plain void

Declared in clika_rt/clika_rt_core.h, line 8478

tensor_ones

clika_rt_error*(* tensor_ones)(const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::ones <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8234

tensor_pin_memory

clika_rt_error*(* tensor_pin_memory)(clika_rt_tensor *self, clika_rt_stream_or_device peer, clika_rt_tensor **out)

ClikaRT::Tensor::pin_memory <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8439

tensor_pow

clika_rt_error*(* tensor_pow)(clika_rt_tensor *self, clika_rt_scalar_or_tensor exponent, clika_rt_tensor **out)

ClikaRT::Tensor::pow <- ClikaRT/compute/tensor.h borrows self exponent.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8649

tensor_release

void(* tensor_release)(clika_rt_tensor *t)

Declared in clika_rt/clika_rt_core.h, line 619

tensor_reshape

clika_rt_error*(* tensor_reshape)(clika_rt_tensor *self, const clika_rt_index_bound *shape, size_t shape_count, clika_rt_tensor **out)

ClikaRT::Tensor::reshape <- ClikaRT/compute/tensor.h borrows self embedded tensors BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8611

tensor_retain

void(* tensor_retain)(clika_rt_tensor *t)

Declared in clika_rt/clika_rt_core.h, line 618

tensor_shape

clika_rt_error*(* tensor_shape)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::shape <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8387

tensor_shape_host_all

clika_rt_error*(* tensor_shape_host_all)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::shape_host <- ClikaRT/compute/tensor.h one form of the overloaded C++ shape_host; the _all suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8626

tensor_shape_host_dim

clika_rt_error*(* tensor_shape_host_dim)(clika_rt_tensor *self, int64_t dim, clika_rt_tensor **out)

ClikaRT::Tensor::shape_host <- ClikaRT/compute/tensor.h one form of the overloaded C++ shape_host; the _dim suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8632

tensor_sizes

clika_rt_error*(* tensor_sizes)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::sizes <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8394

tensor_softmax

clika_rt_error*(* tensor_softmax)(clika_rt_tensor *self, int64_t dim, clika_rt_tensor **out)

ClikaRT::Tensor::softmax <- ClikaRT/compute/tensor.h borrows self C++ defaults (dropped at this surface): dim=-1

Declared in clika_rt/clika_rt_core.h, line 8619

tensor_status

clika_rt_tensor_status(* tensor_status)(clika_rt_tensor *self)

ClikaRT::Tensor::status <- ClikaRT/compute/tensor.h borrows self infallible

Declared in clika_rt/clika_rt_core.h, line 8470

tensor_stream

clika_rt_stream*(* tensor_stream)(clika_rt_tensor *self)

ClikaRT::Tensor::stream <- ClikaRT/compute/tensor.h borrows self infallible; returns an OWNED reference; release when done

Declared in clika_rt/clika_rt_core.h, line 8354

tensor_strides

clika_rt_error*(* tensor_strides)(clika_rt_tensor *self, int64_t *buf, size_t *count)

ClikaRT::Tensor::strides <- ClikaRT/compute/tensor.h borrows self two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 8401

tensor_sub

clika_rt_error*(* tensor_sub)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other, clika_rt_tensor **out)

ClikaRT::Tensor::sub <- ClikaRT/compute/tensor.h borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8590

tensor_sub_inplace

clika_rt_error*(* tensor_sub_inplace)(clika_rt_tensor *self, clika_rt_scalar_or_tensor other)

ClikaRT::Tensor::sub_ <- ClikaRT/compute/tensor.h in-place op borrows self other.kind == CLIKA_RT_SCALAR_OR_TENSOR_ABSENT = not provided; an embedded tensor is BORROWED (contract §11)

Declared in clika_rt/clika_rt_core.h, line 8696

tensor_sum_all

clika_rt_error*(* tensor_sum_all)(clika_rt_tensor *self, clika_rt_tensor **out)

ClikaRT::Tensor::sum <- ClikaRT/compute/tensor.h one form of the overloaded C++ sum; the _all suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8519

tensor_sum_dims

clika_rt_error*(* tensor_sum_dims)(clika_rt_tensor *self, const int64_t *dims, size_t dims_count, uint8_t keepdim, clika_rt_tensor **out)

ClikaRT::Tensor::sum <- ClikaRT/compute/tensor.h one form of the overloaded C++ sum; the _dims suffix names this form borrows self C++ defaults (dropped at this surface): keepdim=false

Declared in clika_rt/clika_rt_core.h, line 8526

tensor_synchronize

clika_rt_error*(* tensor_synchronize)(clika_rt_tensor *self)

ClikaRT::Tensor::synchronize <- ClikaRT/compute/tensor.h borrows self

Declared in clika_rt/clika_rt_core.h, line 8465

tensor_to_device

clika_rt_error*(* tensor_to_device)(clika_rt_tensor *self, clika_rt_device device, clika_rt_tensor **out)

ClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _device suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8413

tensor_to_device_dtype

clika_rt_error*(* tensor_to_device_dtype)(clika_rt_tensor *self, clika_rt_device device, clika_rt_data_type dtype, clika_rt_tensor **out)

ClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _device_dtype suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8427

tensor_to_dtype

clika_rt_error*(* tensor_to_dtype)(clika_rt_tensor *self, clika_rt_data_type dtype, clika_rt_tensor **out)

ClikaRT::Tensor::to <- ClikaRT/compute/tensor.h one form of the overloaded C++ to; the _dtype suffix names this form borrows self

Declared in clika_rt/clika_rt_core.h, line 8420

tensor_to_string

clika_rt_status(* tensor_to_string)(clika_rt_tensor *self, char *buf, size_t *len)

ClikaRT::Tensor::to_string <- ClikaRT/compute/tensor.h borrows self sized-string protocol (contract §5); the status reports BUFFER_TOO_SMALL only

Declared in clika_rt/clika_rt_core.h, line 8502

tensor_to_vec_f32

clika_rt_error*(* tensor_to_vec_f32)(clika_rt_tensor *self, float *buf, size_t *count)

every element of a 0-D or 1-D contiguous tensor as float; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 674

tensor_to_vec_f64

clika_rt_error*(* tensor_to_vec_f64)(clika_rt_tensor *self, double *buf, size_t *count)

every element of a 0-D or 1-D contiguous tensor as double; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 678

tensor_to_vec_i32

clika_rt_error*(* tensor_to_vec_i32)(clika_rt_tensor *self, int32_t *buf, size_t *count)

every element of a 0-D or 1-D contiguous tensor as int32_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 682

tensor_to_vec_i64

clika_rt_error*(* tensor_to_vec_i64)(clika_rt_tensor *self, int64_t *buf, size_t *count)

every element of a 0-D or 1-D contiguous tensor as int64_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 686

tensor_to_vec_u8

clika_rt_error*(* tensor_to_vec_u8)(clika_rt_tensor *self, uint8_t *buf, size_t *count)

every element of a 0-D or 1-D contiguous tensor as uint8_t; two-call sizing: buf == NULL sizes; count carries capacity in, required count out (contract §8)

Declared in clika_rt/clika_rt_core.h, line 690

tensor_zeros

clika_rt_error*(* tensor_zeros)(const int64_t *shape, size_t shape_count, clika_rt_data_type dtype, clika_rt_stream_or_device where, clika_rt_stream_or_device pinned_for, clika_rt_tensor **out)

ClikaRT::Tensor::zeros <- ClikaRT/compute/tensor.h C++ defaults (dropped at this surface): where={}, pinned_for={}

Declared in clika_rt/clika_rt_core.h, line 8225