package owl

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
include module type of struct include Owl_sparse_dok_matrix end
type ('a, 'b) t = ('a, 'b) Owl_sparse_dok_matrix.t
type ('a, 'b) kind = ('a, 'b) Stdlib.Bigarray.kind
Create sparse matrices
val zeros : ?density:float -> ('a, 'b) kind -> int -> int -> ('a, 'b) t
Obtain the basic properties
val shape : ('a, 'b) t -> int * int
val row_num : ('a, 'b) t -> int
val col_num : ('a, 'b) t -> int
val numel : ('a, 'b) t -> int
val nnz : ('a, 'b) t -> int
val density : ('a, 'b) t -> float
val kind : ('a, 'b) t -> ('a, 'b) kind
Manipulate a matrix
val set : ('a, 'b) t -> int -> int -> 'a -> unit
val get : ('a, 'b) t -> int -> int -> 'a
val reset : ('a, 'b) t -> unit
val copy : ('a, 'b) t -> ('a, 'b) t
Iterate elements, columns, and rows
val iteri_nz : (int -> int -> 'a -> unit) -> ('a, 'b) t -> unit
Input/Output and helper functions
val save : ('a, 'b) t -> string -> unit
val load : ('a, 'b) kind -> string -> ('a, 'b) t
OCaml

Innovation. Community. Security.