package arrayjit

  1. Overview
  2. Docs

Module Arrayjit.TnodeSource

Sourcemodule Lazy = Utils.Lazy
Sourcemodule Nd = Ndarray
Sourcemodule Debug_runtime = Utils.Debug_runtime
Sourcetype work =
  1. | Work of (module Minidebug_runtime.Debug_runtime) -> Base.unit -> Base.unit
Sourceval sexp_of_work : work -> Sexplib0.Sexp.t
Sourcetype memory_type =
  1. | Constant
    (*

    The tensor node does not change after initialization.

    *)
  2. | Nonconstant
    (*

    One of: Changed_on_devices, Volatile.

    *)
  3. | Changed_on_devices
    (*

    The tensor node will only change on host via a to_host call.

    *)
  4. | Volatile
    (*

    The tensor node will only change on any device via a from_host or merge call.

    *)
Sourceval memory_type_of_sexp : Sexplib0.Sexp.t -> memory_type
Sourceval sexp_of_memory_type : memory_type -> Sexplib0.Sexp.t
Sourceval compare_memory_type : memory_type -> memory_type -> Base.int
Sourceval equal_memory_type : memory_type -> memory_type -> Base.bool
Sourcetype memory_mode =
  1. | Effectively_constant
    (*

    Either Hosted Constant, or a subset of Virtual.

    *)
  2. | Virtual
    (*

    The tensor node's computations are inlined on a per-scalar basis.

    *)
  3. | Never_virtual
    (*

    One of: Local, On_device, Hosted.

    *)
  4. | Local
    (*

    The full tensor node is cached for the duration of a computation but not persisted across calls to jitted functions. It is not available for merging across devices.

    *)
  5. | Device_only
    (*

    One of: Local, On_device.

    *)
  6. | On_device
    (*

    The tensor node is stored on the devices that compute with it and persisted across function calls. It is available for merging across devices (for devices that support merging / P2P), but not (directly) for visualization or storing to disk.

    *)
  7. | Materialized
    (*

    One of: On_device, Hosted.

    *)
  8. | Hosted of memory_type
    (*

    The tensor node is stored in a globally addressable memory, in addition to on devices where it is computed with (or as part of one of them, if "hosting on device", or only on the host and not on devices, for some backends). It is available for all operations, and visible to OCaml programs as an Ndarray (the optional array of t).

    *)
Sourceval memory_mode_of_sexp : Sexplib0.Sexp.t -> memory_mode
Sourceval sexp_of_memory_mode : memory_mode -> Sexplib0.Sexp.t
Sourceval compare_memory_mode : memory_mode -> memory_mode -> Base.int
Sourceval equal_memory_mode : memory_mode -> memory_mode -> Base.bool
Sourcetype t = {
  1. array : Nd.t Base.option Lazy.t;
  2. prec : Ops.prec;
  3. dims : Base.int Base.array Lazy.t;
  4. id : Base.int;
  5. label : Base.string Base.list;
    (*

    Display information. It is better if the last element of the list is the most narrow or alphanumeric, e.g. an identifier.

    *)
  6. mutable memory_mode : (memory_mode * Base.int) Base.option;
  7. mutable backend_info : Base.Sexp.t;
}
Sourceval sexp_of_t : t -> Sexplib0.Sexp.t
Sourceval name : t -> Base.String.t
Sourceval label : t -> Base.String.t
Sourceval compare : t -> t -> Base.int
Sourceval default_to_most_local : t -> Base.int -> unit
Sourceval is_hosted_force : ?specifically:memory_type -> t -> Base.int -> Base.bool
Sourceval is_materialized_force : t -> Base.int -> bool
Sourceval known_not_materialized : t -> bool
Sourceval known_constant : t -> bool
Sourceval known_non_virtual : t -> bool
Sourceval known_not_param : t -> bool
Sourceval mode_is_unspecified : t -> bool
Sourceval update_memory_mode : t -> memory_mode -> Base.int -> unit
include sig ... end
Sourcetype comparator_witness
Sourceval comparator : (t, comparator_witness) Base__Comparator.t
Sourceval equal : t -> t -> Base.bool
Sourceval hash_fold_t : Base.Hash.state -> t -> Base.Hash.state
Sourceval get_exn : t -> Nd.t
Sourceval has : t -> bool
Sourceval dims_to_string : ?with_axis_numbers:bool -> t -> Base.String.t
Sourceval ident_label : t -> Base.String.t option
Sourceval styled_ident : repeating_nograd_idents:(Base.String.t, 'a) Base.Hashtbl.t -> repeating_grad_idents:(Base.String.t, 'a) Base.Hashtbl.t -> [< `Heuristic_ocannl | `Name_and_label | `Name_only ] -> t -> Base.String.t
Sourceval header : t -> string
Sourcemodule Registry : sig ... end
Sourceval registry : Registry.t
Sourceval create : Ops.prec -> id:Base.int -> label:Base.string Base.list -> dims:int Base.Array.t Lazy.t -> Ops.init_op -> t
Sourceval print_accessible_headers : unit -> Base.unit
Sourceval log_accessible_headers : unit -> unit