The nvmath.bindings module is experimental and potentially subject to future changes.

sp_gemm_estimate_memory_buffersize3#

nvmath.bindings.cusparse.sp_gemm_estimate_memory_buffersize3(
intptr_t handle,
int op_a,
int op_b,
intptr_t alpha,
intptr_t mat_a,
intptr_t mat_b,
intptr_t beta,
intptr_t mat_c,
int compute_type,
int alg,
intptr_t spgemm_descr,
float chunk_fraction,
) size_t[source]#

See cusparseSpGEMM_estimateMemory.

First call this function to query buffer_size3. Then allocate buffer_size3 bytes of device memory and pass that size and device pointer to sp_gemm_estimate_memory_buffersize2().