num

package
v0.0.0-...-e537141 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 9, 2023 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const NDim = Dim(-1)

Variables

This section is empty.

Functions

This section is empty.

Types

type Complex128s

type Complex128s []complex128

type Complex64s

type Complex64s []complex64

type Data

type Data interface {
	DataPointer() (p unsafe.Pointer)
}

type Dim

type Dim int

type Float32s

type Float32s []float32

type Float64s

type Float64s []float64

type Int16s

type Int16s []int16

type Int32s

type Int32s []int32

type Int64s

type Int64s []int64

type Int8s

type Int8s []int8

type Meta

type Meta struct {
	Shape   Shape
	Strides Strides
	// Ndim is the total number of dimensions.
	Ndim int
	// Nelems is the total number of elements.
	Nelems int
}

Meta holds metadata about a given tensor.

type Shape

type Shape []int

Shape contains the number of elements along each dimension of a tensor.

type Strides

type Strides []int

Shape contains the number of strides along each dimension of a tensor.

type Tensor

type Tensor[N Dim] struct {
	Data Data
	Meta Meta
}

type Type

type Type int
const (
	String Type = iota
	Int8
	Int16
	Int32
	Int64
	UInt8
	UInt16
	UInt32
	UInt64
	Float32
	Float64
	Complex64
	Complex128
)

type TypeSet

type TypeSet struct {
	// contains filtered or unexported fields
}

func NewTypeSet

func NewTypeSet(types ...Type) (t TypeSet)

type TypeSetData

type TypeSetData map[Type]empty

type UInt16s

type UInt16s []uint16

type UInt32s

type UInt32s []uint32

type UInt64s

type UInt64s []uint64

type UInt8s

type UInt8s []uint8

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL