powered by
Creates a 1-element tensor containing a single integer value. Useful for indices, counters, and other scalar integer operations.
ggml_new_i32(ctx, value)
Tensor pointer (1-element I32 tensor)
GGML context
Integer value
# \donttest{ ctx <- ggml_init(1024 * 1024) scalar <- ggml_new_i32(ctx, 42) ggml_get_i32(scalar) ggml_free(ctx) # }
Run the code above in your browser using DataLab