package owl-base

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Source file owl_types_common.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# 1 "src/base/types/owl_types_common.ml"
(*
 * OWL - OCaml Scientific and Engineering Computing
 * Copyright (c) 2016-2020 Liang Wang <liang.wang@cl.cam.ac.uk>
 *)

(* basic number type *)

type number =
  | F32 (* single precision float number *)
  | F64 (* double precision float number *)
  | C32 (* single precision complex number *)
  | C64

(* double precision complex number *)

(* basic ndarray type *)

type ('a, 'b) owl_arr = ('a, 'b, Bigarray.c_layout) Bigarray.Genarray.t

(* type of slice definition *)

type index =
  | I of int (* single index *)
  | L of int list (* list of indices *)
  | R of int list

(* index range *)

type slice = index list

(* type of slice definition for internal use in owl_slicing module *)

type index_ =
  | I_ of int
  | L_ of int array
  | R_ of int array

type slice_ = index_ array

(* type of padding in conv?d and maxpool operations *)

type padding =
  | SAME
  | VALID

(* type of various computation devices *)

type device_type =
  | CPU
  | OpenCL
  | CUDA