lgarithm / crystalnet

crystalnet -- a mini core AI library (being refactored, see https://github.com/lgarithm/stdnn-ops)
MIT License
16 stars 3 forks source link

[RFC] define primitive concepts and naming conventions #18

Closed lgarithm closed 6 years ago

lgarithm commented 6 years ago

DRAFT

shape

A shape is a sequence of positive integers. The length of shape is called the rank of the shape. The product of all integers in the sequence is called the dimension, or dim for short, of the shape. The rank of a shape can be 0, the dim of 0-rank shape is 1.

Note:

tensor

Let R be a commutative ring, a tensor of shape s = (k, m, n, ... ) is isomorphic to (((R^...)^n)^m)^k. The rank and dim of a tensor is defined as the rank and dim of its shape. We often omit R when speaking of a tensor.

Note:

function

Function is a meta concept that will not be defined here. A function can be written as F : X_1, \cdots, X_n \to Y F : x_1, \cdots, x_n \to y where n is called the arity of F, and x_1, \cdots, x_n are called the parameters, or arguments of F.

A function can be curried as: F : X_1 -> X_2 \cdots -> X_n -> Y or partially currized as: F: (X_1, \cdots, Xk) -> (X{k + 1}, \cdots, X_n) -> Y

operator

An operator is a tensor function. An operator of arity n is a function that takes n tensors and output 1 tensor. The signature of an n-arity operator is a sequence of n + 1 integers, representing the ranks of the output tensor and the input tensors.

Note:

layer

A layer is a unary operator.

Note:

var and covar

A variable, or var is a free parameter. A covariable, or covar is a bounded parameter.

model

A model is a composed operator of many operators or layers. The arity of a model is the number of bounded parameters.

Note:

agent

An agent is an entity of intelligent, which can percept, learn and react.

An agent will be represented by a Lipschitz Transducer, a continuous extension of Finite State Transducer (FST). (more details: TBD) An agent shall be implemented as a model.

lgarithm commented 6 years ago

TOC