Documentation ¶
Overview ¶
Package tensor provides types that implement n-dimensional arrays.
Index ¶
- type Date32
- func (tb *Date32) Data() arrow.ArrayData
- func (tb *Date32) DataType() arrow.DataType
- func (tsr *Date32) Date32Values() []arrow.Date32
- func (tb *Date32) DimName(i int) string
- func (tb *Date32) DimNames() []string
- func (tb *Date32) IsColMajor() bool
- func (tb *Date32) IsContiguous() bool
- func (tb *Date32) IsMutable() bool
- func (tb *Date32) IsRowMajor() bool
- func (tb *Date32) Len() int
- func (tb *Date32) NumDims() int
- func (tb *Date32) Release()
- func (tb *Date32) Retain()
- func (tb *Date32) Shape() []int64
- func (tb *Date32) Strides() []int64
- func (tsr *Date32) Value(i []int64) arrow.Date32
- type Date64
- func (tb *Date64) Data() arrow.ArrayData
- func (tb *Date64) DataType() arrow.DataType
- func (tsr *Date64) Date64Values() []arrow.Date64
- func (tb *Date64) DimName(i int) string
- func (tb *Date64) DimNames() []string
- func (tb *Date64) IsColMajor() bool
- func (tb *Date64) IsContiguous() bool
- func (tb *Date64) IsMutable() bool
- func (tb *Date64) IsRowMajor() bool
- func (tb *Date64) Len() int
- func (tb *Date64) NumDims() int
- func (tb *Date64) Release()
- func (tb *Date64) Retain()
- func (tb *Date64) Shape() []int64
- func (tb *Date64) Strides() []int64
- func (tsr *Date64) Value(i []int64) arrow.Date64
- type Float32
- func (tb *Float32) Data() arrow.ArrayData
- func (tb *Float32) DataType() arrow.DataType
- func (tb *Float32) DimName(i int) string
- func (tb *Float32) DimNames() []string
- func (tsr *Float32) Float32Values() []float32
- func (tb *Float32) IsColMajor() bool
- func (tb *Float32) IsContiguous() bool
- func (tb *Float32) IsMutable() bool
- func (tb *Float32) IsRowMajor() bool
- func (tb *Float32) Len() int
- func (tb *Float32) NumDims() int
- func (tb *Float32) Release()
- func (tb *Float32) Retain()
- func (tb *Float32) Shape() []int64
- func (tb *Float32) Strides() []int64
- func (tsr *Float32) Value(i []int64) float32
- type Float64
- func (tb *Float64) Data() arrow.ArrayData
- func (tb *Float64) DataType() arrow.DataType
- func (tb *Float64) DimName(i int) string
- func (tb *Float64) DimNames() []string
- func (tsr *Float64) Float64Values() []float64
- func (tb *Float64) IsColMajor() bool
- func (tb *Float64) IsContiguous() bool
- func (tb *Float64) IsMutable() bool
- func (tb *Float64) IsRowMajor() bool
- func (tb *Float64) Len() int
- func (tb *Float64) NumDims() int
- func (tb *Float64) Release()
- func (tb *Float64) Retain()
- func (tb *Float64) Shape() []int64
- func (tb *Float64) Strides() []int64
- func (tsr *Float64) Value(i []int64) float64
- type Int16
- func (tb *Int16) Data() arrow.ArrayData
- func (tb *Int16) DataType() arrow.DataType
- func (tb *Int16) DimName(i int) string
- func (tb *Int16) DimNames() []string
- func (tsr *Int16) Int16Values() []int16
- func (tb *Int16) IsColMajor() bool
- func (tb *Int16) IsContiguous() bool
- func (tb *Int16) IsMutable() bool
- func (tb *Int16) IsRowMajor() bool
- func (tb *Int16) Len() int
- func (tb *Int16) NumDims() int
- func (tb *Int16) Release()
- func (tb *Int16) Retain()
- func (tb *Int16) Shape() []int64
- func (tb *Int16) Strides() []int64
- func (tsr *Int16) Value(i []int64) int16
- type Int32
- func (tb *Int32) Data() arrow.ArrayData
- func (tb *Int32) DataType() arrow.DataType
- func (tb *Int32) DimName(i int) string
- func (tb *Int32) DimNames() []string
- func (tsr *Int32) Int32Values() []int32
- func (tb *Int32) IsColMajor() bool
- func (tb *Int32) IsContiguous() bool
- func (tb *Int32) IsMutable() bool
- func (tb *Int32) IsRowMajor() bool
- func (tb *Int32) Len() int
- func (tb *Int32) NumDims() int
- func (tb *Int32) Release()
- func (tb *Int32) Retain()
- func (tb *Int32) Shape() []int64
- func (tb *Int32) Strides() []int64
- func (tsr *Int32) Value(i []int64) int32
- type Int64
- func (tb *Int64) Data() arrow.ArrayData
- func (tb *Int64) DataType() arrow.DataType
- func (tb *Int64) DimName(i int) string
- func (tb *Int64) DimNames() []string
- func (tsr *Int64) Int64Values() []int64
- func (tb *Int64) IsColMajor() bool
- func (tb *Int64) IsContiguous() bool
- func (tb *Int64) IsMutable() bool
- func (tb *Int64) IsRowMajor() bool
- func (tb *Int64) Len() int
- func (tb *Int64) NumDims() int
- func (tb *Int64) Release()
- func (tb *Int64) Retain()
- func (tb *Int64) Shape() []int64
- func (tb *Int64) Strides() []int64
- func (tsr *Int64) Value(i []int64) int64
- type Int8
- func (tb *Int8) Data() arrow.ArrayData
- func (tb *Int8) DataType() arrow.DataType
- func (tb *Int8) DimName(i int) string
- func (tb *Int8) DimNames() []string
- func (tsr *Int8) Int8Values() []int8
- func (tb *Int8) IsColMajor() bool
- func (tb *Int8) IsContiguous() bool
- func (tb *Int8) IsMutable() bool
- func (tb *Int8) IsRowMajor() bool
- func (tb *Int8) Len() int
- func (tb *Int8) NumDims() int
- func (tb *Int8) Release()
- func (tb *Int8) Retain()
- func (tb *Int8) Shape() []int64
- func (tb *Int8) Strides() []int64
- func (tsr *Int8) Value(i []int64) int8
- type Interface
- type Uint16
- func (tb *Uint16) Data() arrow.ArrayData
- func (tb *Uint16) DataType() arrow.DataType
- func (tb *Uint16) DimName(i int) string
- func (tb *Uint16) DimNames() []string
- func (tb *Uint16) IsColMajor() bool
- func (tb *Uint16) IsContiguous() bool
- func (tb *Uint16) IsMutable() bool
- func (tb *Uint16) IsRowMajor() bool
- func (tb *Uint16) Len() int
- func (tb *Uint16) NumDims() int
- func (tb *Uint16) Release()
- func (tb *Uint16) Retain()
- func (tb *Uint16) Shape() []int64
- func (tb *Uint16) Strides() []int64
- func (tsr *Uint16) Uint16Values() []uint16
- func (tsr *Uint16) Value(i []int64) uint16
- type Uint32
- func (tb *Uint32) Data() arrow.ArrayData
- func (tb *Uint32) DataType() arrow.DataType
- func (tb *Uint32) DimName(i int) string
- func (tb *Uint32) DimNames() []string
- func (tb *Uint32) IsColMajor() bool
- func (tb *Uint32) IsContiguous() bool
- func (tb *Uint32) IsMutable() bool
- func (tb *Uint32) IsRowMajor() bool
- func (tb *Uint32) Len() int
- func (tb *Uint32) NumDims() int
- func (tb *Uint32) Release()
- func (tb *Uint32) Retain()
- func (tb *Uint32) Shape() []int64
- func (tb *Uint32) Strides() []int64
- func (tsr *Uint32) Uint32Values() []uint32
- func (tsr *Uint32) Value(i []int64) uint32
- type Uint64
- func (tb *Uint64) Data() arrow.ArrayData
- func (tb *Uint64) DataType() arrow.DataType
- func (tb *Uint64) DimName(i int) string
- func (tb *Uint64) DimNames() []string
- func (tb *Uint64) IsColMajor() bool
- func (tb *Uint64) IsContiguous() bool
- func (tb *Uint64) IsMutable() bool
- func (tb *Uint64) IsRowMajor() bool
- func (tb *Uint64) Len() int
- func (tb *Uint64) NumDims() int
- func (tb *Uint64) Release()
- func (tb *Uint64) Retain()
- func (tb *Uint64) Shape() []int64
- func (tb *Uint64) Strides() []int64
- func (tsr *Uint64) Uint64Values() []uint64
- func (tsr *Uint64) Value(i []int64) uint64
- type Uint8
- func (tb *Uint8) Data() arrow.ArrayData
- func (tb *Uint8) DataType() arrow.DataType
- func (tb *Uint8) DimName(i int) string
- func (tb *Uint8) DimNames() []string
- func (tb *Uint8) IsColMajor() bool
- func (tb *Uint8) IsContiguous() bool
- func (tb *Uint8) IsMutable() bool
- func (tb *Uint8) IsRowMajor() bool
- func (tb *Uint8) Len() int
- func (tb *Uint8) NumDims() int
- func (tb *Uint8) Release()
- func (tb *Uint8) Retain()
- func (tb *Uint8) Shape() []int64
- func (tb *Uint8) Strides() []int64
- func (tsr *Uint8) Uint8Values() []uint8
- func (tsr *Uint8) Value(i []int64) uint8
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Date32 ¶
type Date32 struct {
// contains filtered or unexported fields
}
Date32 is an n-dim array of date32s.
func NewDate32 ¶
NewDate32 returns a new n-dimensional array of date32s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Date32) Date32Values ¶
func (*Date32) IsColMajor ¶
func (tb *Date32) IsColMajor() bool
func (*Date32) IsContiguous ¶
func (tb *Date32) IsContiguous() bool
func (*Date32) IsMutable ¶
func (tb *Date32) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Date32) IsRowMajor ¶
func (tb *Date32) IsRowMajor() bool
func (*Date32) Release ¶
func (tb *Date32) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Date64 ¶
type Date64 struct {
// contains filtered or unexported fields
}
Date64 is an n-dim array of date64s.
func NewDate64 ¶
NewDate64 returns a new n-dimensional array of date64s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Date64) Date64Values ¶
func (*Date64) IsColMajor ¶
func (tb *Date64) IsColMajor() bool
func (*Date64) IsContiguous ¶
func (tb *Date64) IsContiguous() bool
func (*Date64) IsMutable ¶
func (tb *Date64) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Date64) IsRowMajor ¶
func (tb *Date64) IsRowMajor() bool
func (*Date64) Release ¶
func (tb *Date64) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Float32 ¶
type Float32 struct {
// contains filtered or unexported fields
}
Float32 is an n-dim array of float32s.
func NewFloat32 ¶
NewFloat32 returns a new n-dimensional array of float32s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Float32) Float32Values ¶
func (*Float32) IsColMajor ¶
func (tb *Float32) IsColMajor() bool
func (*Float32) IsContiguous ¶
func (tb *Float32) IsContiguous() bool
func (*Float32) IsMutable ¶
func (tb *Float32) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Float32) IsRowMajor ¶
func (tb *Float32) IsRowMajor() bool
func (*Float32) Release ¶
func (tb *Float32) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Float64 ¶
type Float64 struct {
// contains filtered or unexported fields
}
Float64 is an n-dim array of float64s.
func NewFloat64 ¶
NewFloat64 returns a new n-dimensional array of float64s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Float64) Float64Values ¶
func (*Float64) IsColMajor ¶
func (tb *Float64) IsColMajor() bool
func (*Float64) IsContiguous ¶
func (tb *Float64) IsContiguous() bool
func (*Float64) IsMutable ¶
func (tb *Float64) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Float64) IsRowMajor ¶
func (tb *Float64) IsRowMajor() bool
func (*Float64) Release ¶
func (tb *Float64) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Int16 ¶
type Int16 struct {
// contains filtered or unexported fields
}
Int16 is an n-dim array of int16s.
func NewInt16 ¶
NewInt16 returns a new n-dimensional array of int16s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Int16) Int16Values ¶
func (*Int16) IsColMajor ¶
func (tb *Int16) IsColMajor() bool
func (*Int16) IsContiguous ¶
func (tb *Int16) IsContiguous() bool
func (*Int16) IsMutable ¶
func (tb *Int16) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Int16) IsRowMajor ¶
func (tb *Int16) IsRowMajor() bool
func (*Int16) Release ¶
func (tb *Int16) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Int32 ¶
type Int32 struct {
// contains filtered or unexported fields
}
Int32 is an n-dim array of int32s.
func NewInt32 ¶
NewInt32 returns a new n-dimensional array of int32s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Int32) Int32Values ¶
func (*Int32) IsColMajor ¶
func (tb *Int32) IsColMajor() bool
func (*Int32) IsContiguous ¶
func (tb *Int32) IsContiguous() bool
func (*Int32) IsMutable ¶
func (tb *Int32) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Int32) IsRowMajor ¶
func (tb *Int32) IsRowMajor() bool
func (*Int32) Release ¶
func (tb *Int32) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Int64 ¶
type Int64 struct {
// contains filtered or unexported fields
}
Int64 is an n-dim array of int64s.
func NewInt64 ¶
NewInt64 returns a new n-dimensional array of int64s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Int64) Int64Values ¶
func (*Int64) IsColMajor ¶
func (tb *Int64) IsColMajor() bool
func (*Int64) IsContiguous ¶
func (tb *Int64) IsContiguous() bool
func (*Int64) IsMutable ¶
func (tb *Int64) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Int64) IsRowMajor ¶
func (tb *Int64) IsRowMajor() bool
func (*Int64) Release ¶
func (tb *Int64) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Int8 ¶
type Int8 struct {
// contains filtered or unexported fields
}
Int8 is an n-dim array of int8s.
func NewInt8 ¶
NewInt8 returns a new n-dimensional array of int8s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Int8) Int8Values ¶
func (*Int8) IsColMajor ¶
func (tb *Int8) IsColMajor() bool
func (*Int8) IsContiguous ¶
func (tb *Int8) IsContiguous() bool
func (*Int8) IsMutable ¶
func (tb *Int8) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Int8) IsRowMajor ¶
func (tb *Int8) IsRowMajor() bool
func (*Int8) Release ¶
func (tb *Int8) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
type Interface ¶
type Interface interface { // Retain increases the reference count by 1. // Retain may be called simultaneously from multiple goroutines. Retain() // Release decreases the reference count by 1. // Release may be called simultaneously from multiple goroutines. // When the reference count goes to zero, the memory is freed. Release() // Len returns the number of elements in the tensor. Len() int // Shape returns the size - in each dimension - of the tensor. Shape() []int64 // Strides returns the number of bytes to step in each dimension when traversing the tensor. Strides() []int64 // NumDims returns the number of dimensions of the tensor. NumDims() int // DimName returns the name of the i-th dimension. DimName(i int) string // DimNames returns the names for all dimensions DimNames() []string DataType() arrow.DataType Data() arrow.ArrayData // IsMutable returns whether the underlying data buffer is mutable. IsMutable() bool IsContiguous() bool IsRowMajor() bool IsColMajor() bool }
Interface represents an n-dimensional array of numerical data.
type Uint16 ¶
type Uint16 struct {
// contains filtered or unexported fields
}
Uint16 is an n-dim array of uint16s.
func NewUint16 ¶
NewUint16 returns a new n-dimensional array of uint16s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Uint16) IsColMajor ¶
func (tb *Uint16) IsColMajor() bool
func (*Uint16) IsContiguous ¶
func (tb *Uint16) IsContiguous() bool
func (*Uint16) IsMutable ¶
func (tb *Uint16) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Uint16) IsRowMajor ¶
func (tb *Uint16) IsRowMajor() bool
func (*Uint16) Release ¶
func (tb *Uint16) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
func (*Uint16) Retain ¶
func (tb *Uint16) Retain()
Retain increases the reference count by 1. Retain may be called simultaneously from multiple goroutines.
func (*Uint16) Uint16Values ¶
type Uint32 ¶
type Uint32 struct {
// contains filtered or unexported fields
}
Uint32 is an n-dim array of uint32s.
func NewUint32 ¶
NewUint32 returns a new n-dimensional array of uint32s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Uint32) IsColMajor ¶
func (tb *Uint32) IsColMajor() bool
func (*Uint32) IsContiguous ¶
func (tb *Uint32) IsContiguous() bool
func (*Uint32) IsMutable ¶
func (tb *Uint32) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Uint32) IsRowMajor ¶
func (tb *Uint32) IsRowMajor() bool
func (*Uint32) Release ¶
func (tb *Uint32) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
func (*Uint32) Retain ¶
func (tb *Uint32) Retain()
Retain increases the reference count by 1. Retain may be called simultaneously from multiple goroutines.
func (*Uint32) Uint32Values ¶
type Uint64 ¶
type Uint64 struct {
// contains filtered or unexported fields
}
Uint64 is an n-dim array of uint64s.
func NewUint64 ¶
NewUint64 returns a new n-dimensional array of uint64s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Uint64) IsColMajor ¶
func (tb *Uint64) IsColMajor() bool
func (*Uint64) IsContiguous ¶
func (tb *Uint64) IsContiguous() bool
func (*Uint64) IsMutable ¶
func (tb *Uint64) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Uint64) IsRowMajor ¶
func (tb *Uint64) IsRowMajor() bool
func (*Uint64) Release ¶
func (tb *Uint64) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
func (*Uint64) Retain ¶
func (tb *Uint64) Retain()
Retain increases the reference count by 1. Retain may be called simultaneously from multiple goroutines.
func (*Uint64) Uint64Values ¶
type Uint8 ¶
type Uint8 struct {
// contains filtered or unexported fields
}
Uint8 is an n-dim array of uint8s.
func NewUint8 ¶
NewUint8 returns a new n-dimensional array of uint8s. If strides is nil, row-major strides will be inferred. If names is nil, a slice of empty strings will be created.
func (*Uint8) IsColMajor ¶
func (tb *Uint8) IsColMajor() bool
func (*Uint8) IsContiguous ¶
func (tb *Uint8) IsContiguous() bool
func (*Uint8) IsMutable ¶
func (tb *Uint8) IsMutable() bool
IsMutable returns whether the underlying data buffer is mutable.
func (*Uint8) IsRowMajor ¶
func (tb *Uint8) IsRowMajor() bool
func (*Uint8) Release ¶
func (tb *Uint8) Release()
Release decreases the reference count by 1. Release may be called simultaneously from multiple goroutines. When the reference count goes to zero, the memory is freed.
func (*Uint8) Retain ¶
func (tb *Uint8) Retain()
Retain increases the reference count by 1. Retain may be called simultaneously from multiple goroutines.