Core N2D2

Introduction

In this section we will present the C++ core function that are binded to Python with the framework pybind. The binding of the C++ core is straightforward, thus this section can also be seen as a documentation of the C++ core implementation of N2D2.

If you want to use the raw python binding, you need to compile N2D2. This will create a ‘.so’ file in the lib folder. If you want to use the raw binding, you will need to have this file at the root of your project or in your PYTHONPATH.

You can then access the raw binding by importing N2D2 in your python script with the line import N2D2. It is however not recommended to use the raw binding, you should instead use the n2d2 python library.

DeepNet

Introduction

In order to create a neural network in N2D2 using an INI file, you can use the DeepNetGenerator:

net = N2D2.Network(seed-1)
deepNet = N2D2.DeepNetGenerator.generate(net, "../models/mnist24_16c4s2_24c5s2_150_10.ini")

Before executing the model, the network must first be initialized:

deepNet.initialize()

In order to test the first batch sample from the dataset, we retrieve the StimuliProvider and read the first batch from the test set:

sp = deepNet.getStimuliProvider()
sp.readBatch(N2D2.Database.Test, 0)

We can now run the network on this data:

deepNet.test(N2D2.Database.Test, [])

Finally, in order to retrieve the estimated outputs, one has to retrieve the first and unique target of the model and get the estimated labels and values:

target = deepNet.getTargets()[0]
labels = numpy.array(target.getEstimatedLabels()).flatten()
values = numpy.array(target.getEstimatedLabelsValue()).flatten()
results = list(zip(labels, values))

print(results)
[(1, 0.15989691), (1, 0.1617092), (9, 0.14962792), (9, 0.16899541), (1, 0.16261548), (1, 0.17289816), (1, 0.13728766), (1, 0.15315214), (1, 0.14424478), (9, 0.17937174), (9, 0.1518211), (1, 0.12860791), (9, 0.17310674), (9, 0.14563303), (1, 0.17823018), (9, 0.14206158), (1, 0.18292117), (9, 0.14831856), (1, 0.22245243), (9, 0.1745578), (1, 0.20414244), (1, 0.26987872), (1, 0.16570412), (9, 0.17435187)]

API Reference

class N2D2.DeepNet
__init__(self: N2D2.DeepNet, net: N2D2.Network) None
addCMonitor(self: N2D2.DeepNet, name: str, monitor: N2D2::CMonitor) None
addCell(self: N2D2.DeepNet, cell: N2D2::Cell, parents: List[N2D2::Cell]) None
addMonitor(self: N2D2.DeepNet, name: str, monitor: N2D2::Monitor) None
addTarget(self: N2D2.DeepNet, target: N2D2.Target) None
backPropagate(self: N2D2.DeepNet, timings: List[Tuple[str, float]] = []) None
cReset(self: N2D2.DeepNet, timestamp: int = 0) None
cTargetsProcess(self: N2D2.DeepNet, set: N2D2.Database.StimuliSet) None
cTicks(self: N2D2.DeepNet, start: int, stop: int, timestep: int, record: bool = False) None
exportNetworkFreeParameters(*args, **kwargs)

Overloaded function.

  1. exportNetworkFreeParameters(self: N2D2.DeepNet, dirName: str) -> None

  2. exportNetworkFreeParameters(self: N2D2.DeepNet, dirName: str) -> None

exportNetworkSolverParameters(self: N2D2.DeepNet, dirName: str) None
fuseBatchNorm(self: N2D2.DeepNet) None
getCMonitor(self: N2D2.DeepNet, name: str) N2D2::CMonitor
getCell(self: N2D2.DeepNet, name: str) N2D2::Cell
getCell_Frame_Top(self: N2D2.DeepNet, name: str) N2D2::Cell_Frame_Top
getCells(self: N2D2.DeepNet) Dict[str, N2D2::Cell]
getChildCells(self: N2D2.DeepNet, name: str) List[N2D2::Cell]
getDatabase(self: N2D2.DeepNet) N2D2.Database
getLayers(self: N2D2.DeepNet) List[List[str]]
getMasterDevice(self: N2D2.DeepNet) int
getMonitor(self: N2D2.DeepNet, name: str) N2D2::Monitor
getName(self: N2D2.DeepNet) str
getNetwork(self: N2D2.DeepNet) N2D2.Network
getParentCells(self: N2D2.DeepNet, name: str) List[N2D2::Cell]
getStimuliProvider(self: N2D2.DeepNet) N2D2.StimuliProvider
getTargets(self: N2D2.DeepNet) List[N2D2.Target]
importNetworkFreeParameters(*args, **kwargs)

Overloaded function.

  1. importNetworkFreeParameters(self: N2D2.DeepNet, dirName: str, ignoreNotExists: bool = False) -> None

  2. importNetworkFreeParameters(self: N2D2.DeepNet, dirName: str, weightName: str) -> None

initialize(self: N2D2.DeepNet) None
initializeCMonitors(self: N2D2.DeepNet, nbTimesteps: int) None
load(self: N2D2.DeepNet, dirName: str) None
loadNetworkParameters(self: N2D2.DeepNet) None
log(self: N2D2.DeepNet, baseName: str, set: N2D2.Database.StimuliSet) None
logEstimatedLabels(self: N2D2.DeepNet, dirName: str) None
logEstimatedLabelsJSON(self: N2D2.DeepNet, dirName: str) None
logFreeParameters(self: N2D2.DeepNet, dirName: str) None
logLabelsLegend(self: N2D2.DeepNet, fileName: str) None
logLabelsMapping(self: N2D2.DeepNet, fileName: str, withStats: bool = False) None
logReceptiveFields(self: N2D2.DeepNet, fileName: str) None
logStats(self: N2D2.DeepNet, dirName: str) None
logTimings(self: N2D2.DeepNet, fileName: str, timings: List[Tuple[str, float]]) None
propagate(*args, **kwargs)

Overloaded function.

  1. propagate(self: N2D2.DeepNet, inference: bool) -> None

  2. propagate(self: N2D2.DeepNet, set: N2D2.Database.StimuliSet, inference: bool, timings: List[Tuple[str, float]] = 0) -> None

removeCell(self: N2D2.DeepNet, cell: N2D2::Cell, reconnect: bool = True) None
removeDropout(self: N2D2.DeepNet) None
save(self: N2D2.DeepNet, dirName: str) None
saveNetworkParameters(self: N2D2.DeepNet) None
setDatabase(self: N2D2.DeepNet, database: N2D2.Database) None
setStimuliProvider(self: N2D2.DeepNet, sp: N2D2.StimuliProvider) None
spikeCodingCompare(self: N2D2.DeepNet, dirName: str, idx: int) None
test(self: N2D2.DeepNet, set: N2D2.Database.StimuliSet, timings: List[Tuple[str, float]] = 0) None
update(*args, **kwargs)

Overloaded function.

  1. update(self: N2D2.DeepNet, log: bool, start: int, stop: int = 0, update: bool = True) -> List[Tuple[str, int]]

  2. update(self: N2D2.DeepNet, timings: List[Tuple[str, float]] = []) -> None

Cells

Cell

AnchorCell

class N2D2.AnchorCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

BatchNormCell

class N2D2.BatchNormCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBiasSolver(self: N2D2.BatchNormCell) N2D2.Solver
getBiases(self: N2D2.BatchNormCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getEpsilon(self: N2D2.BatchNormCell) float
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMeans(self: N2D2.BatchNormCell) N2D2.BaseTensor
getMovingAverageMomentum(self: N2D2.BatchNormCell) float
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getScaleSolver(self: N2D2.BatchNormCell) N2D2.Solver
getScales(self: N2D2.BatchNormCell) N2D2.BaseTensor
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getVariances(self: N2D2.BatchNormCell) N2D2.BaseTensor
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setBias(self: N2D2.BatchNormCell, index: int, bias: N2D2.BaseTensor) None
setBiasSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setMean(self: N2D2.BatchNormCell, index: int, mean: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setScale(self: N2D2.BatchNormCell, index: int, scale: N2D2.BaseTensor) None
setScaleSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setVariance(self: N2D2.BatchNormCell, index: int, variance: N2D2.BaseTensor) None

Cell

class N2D2.Cell

Cell is the base object for any kind of layer composing a deep network. It provides the base interface required.

class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ConvCell

class N2D2.ConvCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class WeightsExportFormat

Members:

OCHW

HWCO

__init__(self: N2D2.ConvCell.WeightsExportFormat, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.ConvCell) N2D2.Filler
getBiasSolver(self: N2D2.ConvCell) N2D2.Solver
getBiases(self: N2D2.ConvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDilationX(self: N2D2.ConvCell) int
getDilationY(self: N2D2.ConvCell) int
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.ConvCell) int
getKernelWidth(self: N2D2.ConvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.ConvCell) int
getPaddingY(self: N2D2.ConvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.ConvCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.ConvCell) int
getStrideY(self: N2D2.ConvCell) int
getSubSampleX(self: N2D2.ConvCell) int
getSubSampleY(self: N2D2.ConvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.ConvCell) N2D2.Filler
getWeightsSolver(self: N2D2.ConvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.ConvCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None

DeconvCell

class N2D2.DeconvCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.DeconvCell) N2D2.Filler
getBiasSolver(self: N2D2.DeconvCell) N2D2.Solver
getBiases(self: N2D2.DeconvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDilationX(self: N2D2.DeconvCell) int
getDilationY(self: N2D2.DeconvCell) int
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.DeconvCell) int
getKernelWidth(self: N2D2.DeconvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.DeconvCell) int
getPaddingY(self: N2D2.DeconvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.DeconvCell) int
getStrideY(self: N2D2.DeconvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.DeconvCell) N2D2.Filler
getWeightsSolver(self: N2D2.DeconvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None

DropoutCell

class N2D2.DropoutCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDropout(self: N2D2.DropoutCell) float
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ElemWiseCell

class N2D2.ElemWiseCell
class CoeffMode

Members:

PerLayer

PerInput

PerChannel

__init__(self: N2D2.ElemWiseCell.CoeffMode, value: int) None
property name
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Operation

Members:

Sum

AbsSum

EuclideanSum

Prod

Max

__init__(self: N2D2.ElemWiseCell.Operation, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getCoeffMode(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.CoeffMode
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOperation(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.Operation
getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getShifts(self: N2D2.ElemWiseCell) List[float]
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeights(self: N2D2.ElemWiseCell) List[float]
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

FMPCell

class N2D2.FMPCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

FcCell

class N2D2.FcCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class WeightsExportFormat

Members:

OC

CO

__init__(self: N2D2.FcCell.WeightsExportFormat, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.FcCell) N2D2.Filler
getBiasSolver(self: N2D2.FcCell) N2D2.Solver
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.FcCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.FcCell) N2D2.Filler
getWeightsSolver(self: N2D2.FcCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.FcCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.FcCell, solver: N2D2.Solver) None

LRNCell

class N2D2.LRNCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

LSTMCell

class N2D2.LSTMCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

NormalizeCell

class N2D2.NormalizeCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Norm

Members:

L1

L2

__init__(self: N2D2.NormalizeCell.Norm, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ObjectDetCell

class N2D2.ObjectDetCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

PaddingCell

class N2D2.PaddingCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBotPad(self: N2D2.PaddingCell) int
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getLeftPad(self: N2D2.PaddingCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getRightPad(self: N2D2.PaddingCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTopPad(self: N2D2.PaddingCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

PoolCell

class N2D2.PoolCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ProposalCell

class N2D2.ProposalCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ROIPoolingCell

class N2D2.ROIPoolingCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ROIPooling

Members:

Max

Average

Bilinear

BilinearTF

__init__(self: N2D2.ROIPoolingCell.ROIPooling, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

RPCell

class N2D2.RPCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ResizeCell

class N2D2.ResizeCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ResizeMode

Members:

Bilinear

BilinearTF

NearestNeighbor

__init__(self: N2D2.ResizeCell.ResizeMode, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMode(self: N2D2.ResizeCell) N2D2::ResizeCell::ResizeMode
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getResizeOutputHeight(self: N2D2.ResizeCell) int
getResizeOutputWidth(self: N2D2.ResizeCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.ResizeCell) str
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ScalingCell

class N2D2.ScalingCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getScaling(self: N2D2.ScalingCell) N2D2.Scaling
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

SoftmaxCell

class N2D2.SoftmaxCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getGroupSize(self: N2D2.SoftmaxCell) int
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWithLoss(self: N2D2.SoftmaxCell) bool
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWithLoss(self: N2D2.SoftmaxCell, withLoss: bool) None

TargetBiasCell

class N2D2.TargetBiasCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

ThresholdCell

class N2D2.ThresholdCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

TransformationCell

class N2D2.TransformationCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTransformation(self: N2D2.TransformationCell) N2D2.Transformation
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

UnpoolCell

class N2D2.UnpoolCell
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.UnpoolCell.Pooling, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

clearInputs()

Clear input Cells

exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None

Frame

AnchorCell_Frame

class N2D2.AnchorCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.AnchorCell_Frame, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, detectorType: N2D2.DetectorType, inputFormat: N2D2.Format, anchors: List[N2D2.Anchor], scoresCls: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

AnchorCell_Frame_CUDA

class N2D2.AnchorCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.AnchorCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, detectorType: N2D2.DetectorType, inputFormat: N2D2.Format, anchors: List[N2D2.Anchor], scoresCls: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

BatchNormCell_Frame_float

class N2D2.BatchNormCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.BatchNormCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBiasSolver(self: N2D2.BatchNormCell) N2D2.Solver
getBiases(self: N2D2.BatchNormCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getEpsilon(self: N2D2.BatchNormCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMeans(self: N2D2.BatchNormCell) N2D2.BaseTensor
getMovingAverageMomentum(self: N2D2.BatchNormCell) float
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaleSolver(self: N2D2.BatchNormCell) N2D2.Solver
getScales(self: N2D2.BatchNormCell) N2D2.BaseTensor
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getVariances(self: N2D2.BatchNormCell) N2D2.BaseTensor
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.BatchNormCell, index: int, bias: N2D2.BaseTensor) None
setBiasSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setMean(self: N2D2.BatchNormCell, index: int, mean: N2D2.BaseTensor) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setScale(self: N2D2.BatchNormCell, index: int, scale: N2D2.BaseTensor) None
setScaleSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setVariance(self: N2D2.BatchNormCell, index: int, variance: N2D2.BaseTensor) None
update(self: N2D2.Cell_Frame_Top) None

BatchNormCell_Frame_double

class N2D2.BatchNormCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.BatchNormCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBiasSolver(self: N2D2.BatchNormCell) N2D2.Solver
getBiases(self: N2D2.BatchNormCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getEpsilon(self: N2D2.BatchNormCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMeans(self: N2D2.BatchNormCell) N2D2.BaseTensor
getMovingAverageMomentum(self: N2D2.BatchNormCell) float
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaleSolver(self: N2D2.BatchNormCell) N2D2.Solver
getScales(self: N2D2.BatchNormCell) N2D2.BaseTensor
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getVariances(self: N2D2.BatchNormCell) N2D2.BaseTensor
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.BatchNormCell, index: int, bias: N2D2.BaseTensor) None
setBiasSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setMean(self: N2D2.BatchNormCell, index: int, mean: N2D2.BaseTensor) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setScale(self: N2D2.BatchNormCell, index: int, scale: N2D2.BaseTensor) None
setScaleSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setVariance(self: N2D2.BatchNormCell, index: int, variance: N2D2.BaseTensor) None
update(self: N2D2.Cell_Frame_Top) None

BatchNormCell_Frame_CUDA_float

class N2D2.BatchNormCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.BatchNormCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBiasSolver(self: N2D2.BatchNormCell) N2D2.Solver
getBiases(self: N2D2.BatchNormCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getEpsilon(self: N2D2.BatchNormCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMeans(self: N2D2.BatchNormCell) N2D2.BaseTensor
getMovingAverageMomentum(self: N2D2.BatchNormCell) float
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaleSolver(self: N2D2.BatchNormCell) N2D2.Solver
getScales(self: N2D2.BatchNormCell) N2D2.BaseTensor
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getVariances(self: N2D2.BatchNormCell) N2D2.BaseTensor
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.BatchNormCell, index: int, bias: N2D2.BaseTensor) None
setBiasSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setMean(self: N2D2.BatchNormCell, index: int, mean: N2D2.BaseTensor) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setScale(self: N2D2.BatchNormCell, index: int, scale: N2D2.BaseTensor) None
setScaleSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setVariance(self: N2D2.BatchNormCell, index: int, variance: N2D2.BaseTensor) None
update(self: N2D2.Cell_Frame_Top) None

BatchNormCell_Frame_CUDA_double

class N2D2.BatchNormCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.BatchNormCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBiasSolver(self: N2D2.BatchNormCell) N2D2.Solver
getBiases(self: N2D2.BatchNormCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getEpsilon(self: N2D2.BatchNormCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMeans(self: N2D2.BatchNormCell) N2D2.BaseTensor
getMovingAverageMomentum(self: N2D2.BatchNormCell) float
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaleSolver(self: N2D2.BatchNormCell) N2D2.Solver
getScales(self: N2D2.BatchNormCell) N2D2.BaseTensor
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getVariances(self: N2D2.BatchNormCell) N2D2.BaseTensor
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.BatchNormCell, index: int, bias: N2D2.BaseTensor) None
setBiasSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setMean(self: N2D2.BatchNormCell, index: int, mean: N2D2.BaseTensor) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setScale(self: N2D2.BatchNormCell, index: int, scale: N2D2.BaseTensor) None
setScaleSolver(self: N2D2.BatchNormCell, solver: N2D2.Solver) None
setVariance(self: N2D2.BatchNormCell, index: int, variance: N2D2.BaseTensor) None
update(self: N2D2.Cell_Frame_Top) None

Cell_Frame_float

class N2D2.Cell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

Cell_Frame_double

class N2D2.Cell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

Cell_Frame_CUDA_float

class N2D2.Cell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

Cell_Frame_CUDA_double

class N2D2.Cell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(*args, **kwargs)
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

Cell_Frame_Top

class N2D2.Cell_Frame_Top
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(*args, **kwargs)
addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getDiffInputs(self: N2D2.Cell_Frame_Top) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

load(self: N2D2.Cell_Frame_Top, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell_Frame_Top, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
update(self: N2D2.Cell_Frame_Top) None

ConvCell_Frame_float

class N2D2.ConvCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OCHW

HWCO

__init__(self: N2D2.ConvCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.ConvCell_Frame_float, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, subSampleDims: List[int] = [1, 1], strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.ConvCell) N2D2.Filler
getBiasSolver(self: N2D2.ConvCell) N2D2.Solver
getBiases(self: N2D2.ConvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.ConvCell) int
getDilationY(self: N2D2.ConvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.ConvCell) int
getKernelWidth(self: N2D2.ConvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.ConvCell) int
getPaddingY(self: N2D2.ConvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.ConvCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.ConvCell) int
getStrideY(self: N2D2.ConvCell) int
getSubSampleX(self: N2D2.ConvCell) int
getSubSampleY(self: N2D2.ConvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.ConvCell) N2D2.Filler
getWeightsSolver(self: N2D2.ConvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.ConvCell_Frame_float) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.ConvCell_Frame_float) None
resetWeights(self: N2D2.ConvCell_Frame_float) None
resetWeightsSolver(self: N2D2.ConvCell_Frame_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.ConvCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

ConvCell_Frame_double

class N2D2.ConvCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OCHW

HWCO

__init__(self: N2D2.ConvCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.ConvCell_Frame_double, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, subSampleDims: List[int] = [1, 1], strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.ConvCell) N2D2.Filler
getBiasSolver(self: N2D2.ConvCell) N2D2.Solver
getBiases(self: N2D2.ConvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.ConvCell) int
getDilationY(self: N2D2.ConvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.ConvCell) int
getKernelWidth(self: N2D2.ConvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.ConvCell) int
getPaddingY(self: N2D2.ConvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.ConvCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.ConvCell) int
getStrideY(self: N2D2.ConvCell) int
getSubSampleX(self: N2D2.ConvCell) int
getSubSampleY(self: N2D2.ConvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.ConvCell) N2D2.Filler
getWeightsSolver(self: N2D2.ConvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.ConvCell_Frame_double) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.ConvCell_Frame_double) None
resetWeights(self: N2D2.ConvCell_Frame_double) None
resetWeightsSolver(self: N2D2.ConvCell_Frame_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.ConvCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

ConvCell_Frame_CUDA_float

class N2D2.ConvCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OCHW

HWCO

__init__(self: N2D2.ConvCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.ConvCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, subSampleDims: List[int] = [1, 1], strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.ConvCell) N2D2.Filler
getBiasSolver(self: N2D2.ConvCell) N2D2.Solver
getBiases(self: N2D2.ConvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getDiffSynapses(self: N2D2.ConvCell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.ConvCell) int
getDilationY(self: N2D2.ConvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.ConvCell) int
getKernelWidth(self: N2D2.ConvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.ConvCell) int
getPaddingY(self: N2D2.ConvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.ConvCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.ConvCell) int
getStrideY(self: N2D2.ConvCell) int
getSubSampleX(self: N2D2.ConvCell) int
getSubSampleY(self: N2D2.ConvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.ConvCell) N2D2.Filler
getWeightsSolver(self: N2D2.ConvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.ConvCell_Frame_CUDA_float) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.ConvCell_Frame_CUDA_float) None
resetWeights(self: N2D2.ConvCell_Frame_CUDA_float) None
resetWeightsSolver(self: N2D2.ConvCell_Frame_CUDA_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.ConvCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

ConvCell_Frame_CUDA_double

class N2D2.ConvCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OCHW

HWCO

__init__(self: N2D2.ConvCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.ConvCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, subSampleDims: List[int] = [1, 1], strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.ConvCell) N2D2.Filler
getBiasSolver(self: N2D2.ConvCell) N2D2.Solver
getBiases(self: N2D2.ConvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getDiffSynapses(self: N2D2.ConvCell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.ConvCell) int
getDilationY(self: N2D2.ConvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.ConvCell) int
getKernelWidth(self: N2D2.ConvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.ConvCell) int
getPaddingY(self: N2D2.ConvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.ConvCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.ConvCell) int
getStrideY(self: N2D2.ConvCell) int
getSubSampleX(self: N2D2.ConvCell) int
getSubSampleY(self: N2D2.ConvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.ConvCell) N2D2.Filler
getWeightsSolver(self: N2D2.ConvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.ConvCell_Frame_CUDA_double) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.ConvCell_Frame_CUDA_double) None
resetWeights(self: N2D2.ConvCell_Frame_CUDA_double) None
resetWeightsSolver(self: N2D2.ConvCell_Frame_CUDA_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.ConvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.ConvCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.ConvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.ConvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.ConvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

DeconvCell_Frame_float

class N2D2.DeconvCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DeconvCell_Frame_float, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.DeconvCell) N2D2.Filler
getBiasSolver(self: N2D2.DeconvCell) N2D2.Solver
getBiases(self: N2D2.DeconvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.DeconvCell) int
getDilationY(self: N2D2.DeconvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.DeconvCell) int
getKernelWidth(self: N2D2.DeconvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.DeconvCell) int
getPaddingY(self: N2D2.DeconvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.DeconvCell) int
getStrideY(self: N2D2.DeconvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.DeconvCell) N2D2.Filler
getWeightsSolver(self: N2D2.DeconvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetWeightsSolver(self: N2D2.DeconvCell_Frame_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

DeconvCell_Frame_double

class N2D2.DeconvCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DeconvCell_Frame_double, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.DeconvCell) N2D2.Filler
getBiasSolver(self: N2D2.DeconvCell) N2D2.Solver
getBiases(self: N2D2.DeconvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.DeconvCell) int
getDilationY(self: N2D2.DeconvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.DeconvCell) int
getKernelWidth(self: N2D2.DeconvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.DeconvCell) int
getPaddingY(self: N2D2.DeconvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.DeconvCell) int
getStrideY(self: N2D2.DeconvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.DeconvCell) N2D2.Filler
getWeightsSolver(self: N2D2.DeconvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetWeightsSolver(self: N2D2.DeconvCell_Frame_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

DeconvCell_Frame_CUDA_float

class N2D2.DeconvCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DeconvCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.DeconvCell) N2D2.Filler
getBiasSolver(self: N2D2.DeconvCell) N2D2.Solver
getBiases(self: N2D2.DeconvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.DeconvCell) int
getDilationY(self: N2D2.DeconvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.DeconvCell) int
getKernelWidth(self: N2D2.DeconvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.DeconvCell) int
getPaddingY(self: N2D2.DeconvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.DeconvCell) int
getStrideY(self: N2D2.DeconvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.DeconvCell) N2D2.Filler
getWeightsSolver(self: N2D2.DeconvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetWeightsSolver(self: N2D2.DeconvCell_Frame_CUDA_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

DeconvCell_Frame_CUDA_double

class N2D2.DeconvCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DeconvCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, kernelDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], dilationDims: List[int] = [1, 1], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.DeconvCell) N2D2.Filler
getBiasSolver(self: N2D2.DeconvCell) N2D2.Solver
getBiases(self: N2D2.DeconvCell) N2D2.BaseTensor
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getDilationX(self: N2D2.DeconvCell) int
getDilationY(self: N2D2.DeconvCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getKernelHeight(self: N2D2.DeconvCell) int
getKernelWidth(self: N2D2.DeconvCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.DeconvCell) int
getPaddingY(self: N2D2.DeconvCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.DeconvCell) int
getStrideY(self: N2D2.DeconvCell) int
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.DeconvCell) N2D2.Filler
getWeightsSolver(self: N2D2.DeconvCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetWeightsSolver(self: N2D2.DeconvCell_Frame_CUDA_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.DeconvCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWeight(self: N2D2.DeconvCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.DeconvCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.DeconvCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

DropoutCell_Frame_float

class N2D2.DropoutCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DropoutCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getDropout(self: N2D2.DropoutCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

DropoutCell_Frame_double

class N2D2.DropoutCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DropoutCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getDropout(self: N2D2.DropoutCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

DropoutCell_Frame_CUDA_float

class N2D2.DropoutCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DropoutCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getDropout(self: N2D2.DropoutCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

DropoutCell_Frame_CUDA_double

class N2D2.DropoutCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.DropoutCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getDropout(self: N2D2.DropoutCell) float
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ElemWiseCell_Frame

class N2D2.ElemWiseCell_Frame
class CoeffMode

Members:

PerLayer

PerInput

PerChannel

__init__(self: N2D2.ElemWiseCell.CoeffMode, value: int) None
property name
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Operation

Members:

Sum

AbsSum

EuclideanSum

Prod

Max

__init__(self: N2D2.ElemWiseCell.Operation, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ElemWiseCell_Frame, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, operation: N2D2.ElemWiseCell.Operation = <Operation.Sum: 0>, mode: N2D2.ElemWiseCell.CoeffMode = <CoeffMode.PerLayer: 0>, weights: List[float] = [], shifts: List[float] = [], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getCoeffMode(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.CoeffMode
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOperation(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.Operation
getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getShifts(self: N2D2.ElemWiseCell) List[float]
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeights(self: N2D2.ElemWiseCell) List[float]
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ElemWiseCell_Frame_CUDA

class N2D2.ElemWiseCell_Frame_CUDA
class CoeffMode

Members:

PerLayer

PerInput

PerChannel

__init__(self: N2D2.ElemWiseCell.CoeffMode, value: int) None
property name
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Operation

Members:

Sum

AbsSum

EuclideanSum

Prod

Max

__init__(self: N2D2.ElemWiseCell.Operation, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ElemWiseCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, operation: N2D2.ElemWiseCell.Operation = <Operation.Sum: 0>, mode: N2D2.ElemWiseCell.CoeffMode = <CoeffMode.PerLayer: 0>, weights: List[float] = [], shifts: List[float] = [], activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getCoeffMode(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.CoeffMode
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOperation(self: N2D2.ElemWiseCell) N2D2.ElemWiseCell.Operation
getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getShifts(self: N2D2.ElemWiseCell) List[float]
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeights(self: N2D2.ElemWiseCell) List[float]
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

FMPCell_Frame

class N2D2.FMPCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.FMPCell_Frame, deepNet: N2D2.DeepNet, name: str, scalingRatio: float, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

FMPCell_Frame_CUDA

class N2D2.FMPCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.FMPCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, scalingRatio: float, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

FcCell_Frame_float

class N2D2.FcCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OC

CO

__init__(self: N2D2.FcCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.FcCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.FcCell) N2D2.Filler
getBiasSolver(self: N2D2.FcCell) N2D2.Solver
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.FcCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.FcCell) N2D2.Filler
getWeightsSolver(self: N2D2.FcCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.FcCell_Frame_float) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.FcCell_Frame_float) None
resetWeights(self: N2D2.FcCell_Frame_float) None
resetWeightsSolver(self: N2D2.FcCell_Frame_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.FcCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

FcCell_Frame_double

class N2D2.FcCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OC

CO

__init__(self: N2D2.FcCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.FcCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.FcCell) N2D2.Filler
getBiasSolver(self: N2D2.FcCell) N2D2.Solver
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.FcCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.FcCell) N2D2.Filler
getWeightsSolver(self: N2D2.FcCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.FcCell_Frame_double) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.FcCell_Frame_double) None
resetWeights(self: N2D2.FcCell_Frame_double) None
resetWeightsSolver(self: N2D2.FcCell_Frame_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.FcCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

FcCell_Frame_CUDA_float

class N2D2.FcCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OC

CO

__init__(self: N2D2.FcCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.FcCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.FcCell) N2D2.Filler
getBiasSolver(self: N2D2.FcCell) N2D2.Solver
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.FcCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.FcCell) N2D2.Filler
getWeightsSolver(self: N2D2.FcCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.FcCell_Frame_CUDA_float) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.FcCell_Frame_CUDA_float) None
resetWeights(self: N2D2.FcCell_Frame_CUDA_float) None
resetWeightsSolver(self: N2D2.FcCell_Frame_CUDA_float, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.FcCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

FcCell_Frame_CUDA_double

class N2D2.FcCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
class WeightsExportFormat

Members:

OC

CO

__init__(self: N2D2.FcCell.WeightsExportFormat, value: int) None
property name
__init__(self: N2D2.FcCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
getBiasFiller(self: N2D2.FcCell) N2D2.Filler
getBiasSolver(self: N2D2.FcCell) N2D2.Solver
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getQuantizer(self: N2D2.FcCell) N2D2::QuantizerCell
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
getWeightsFiller(self: N2D2.FcCell) N2D2.Filler
getWeightsSolver(self: N2D2.FcCell) N2D2.Solver
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
initializeWeightQuantizer(self: N2D2.FcCell_Frame_CUDA_double) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

resetBias(self: N2D2.FcCell_Frame_CUDA_double) None
resetWeights(self: N2D2.FcCell_Frame_CUDA_double) None
resetWeightsSolver(self: N2D2.FcCell_Frame_CUDA_double, solver: N2D2.Solver) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setBias(self: N2D2.FcCell, output: int, value: N2D2.BaseTensor) None
setBiasFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setBiasSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setQuantizer(self: N2D2.FcCell, quantizer: N2D2::QuantizerCell) None
setWeight(self: N2D2.FcCell, output: int, channel: int, value: N2D2.BaseTensor) None
setWeightsFiller(self: N2D2.FcCell, filler: N2D2.Filler) None
setWeightsSolver(self: N2D2.FcCell, solver: N2D2.Solver) None
update(self: N2D2.Cell_Frame_Top) None

LRNCell_Frame_float

class N2D2.LRNCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LRNCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

LRNCell_Frame_double

class N2D2.LRNCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LRNCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

LRNCell_Frame_CUDA_float

class N2D2.LRNCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LRNCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

LRNCell_Frame_CUDA_double

class N2D2.LRNCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LRNCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

LSTMCell_Frame_CUDA_float

class N2D2.LSTMCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LSTMCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, seqLength: int, batchSize: int, inputDim: int, numberLayers: int, hiddenSize: int, algo: int, nbOutputs: int, bidirectional: int, inputMode: int, dropout: float, singleBackpropFeeding: bool) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

LSTMCell_Frame_CUDA_double

class N2D2.LSTMCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.LSTMCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, seqLength: int, batchSize: int, inputDim: int, numberLayers: int, hiddenSize: int, algo: int, nbOutputs: int, bidirectional: int, inputMode: int, dropout: float, singleBackpropFeeding: bool) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

NormalizeCell_Frame_float

class N2D2.NormalizeCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Norm

Members:

L1

L2

__init__(self: N2D2.NormalizeCell.Norm, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.NormalizeCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, norm: N2D2.NormalizeCell.Norm) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

NormalizeCell_Frame_double

class N2D2.NormalizeCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Norm

Members:

L1

L2

__init__(self: N2D2.NormalizeCell.Norm, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.NormalizeCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, norm: N2D2.NormalizeCell.Norm) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

NormalizeCell_Frame_CUDA_float

class N2D2.NormalizeCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Norm

Members:

L1

L2

__init__(self: N2D2.NormalizeCell.Norm, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.NormalizeCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, norm: N2D2.NormalizeCell.Norm) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

NormalizeCell_Frame_CUDA_double

class N2D2.NormalizeCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Norm

Members:

L1

L2

__init__(self: N2D2.NormalizeCell.Norm, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.NormalizeCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, norm: N2D2.NormalizeCell.Norm) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ObjectDetCell_Frame

class N2D2.ObjectDetCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ObjectDetCell_Frame, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, nbOutputs: int, nbAnchors: int, inputFormat: N2D2.Format, pixelFormat: N2D2.PixelFormat, nbProposals: int, nbClass: int, nmsThreshold: float = 0.5, scoreThreshold: List[float] = [0.5], numParts: List[int] = [], numTemplates: List[int] = [], anchors: List[N2D2.Anchor] = []) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ObjectDetCell_Frame_CUDA

class N2D2.ObjectDetCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ObjectDetCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, nbOutputs: int, nbAnchors: int, inputFormat: N2D2.Format, pixelFormat: N2D2.PixelFormat, nbProposals: int, nbClass: int, nmsThreshold: float = 0.5, scoreThreshold: List[float] = [0.5], numParts: List[int] = [], numTemplates: List[int] = [], anchors: List[N2D2.Anchor] = []) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PaddingCell_Frame

class N2D2.PaddingCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PaddingCell_Frame, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, topPad: int = 0, botPad: int = 0, leftPad: int = 0, rightPad: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBotPad(self: N2D2.PaddingCell) int
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getLeftPad(self: N2D2.PaddingCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getRightPad(self: N2D2.PaddingCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTopPad(self: N2D2.PaddingCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PaddingCell_Frame_CUDA

class N2D2.PaddingCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PaddingCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, topPad: int = 0, botPad: int = 0, leftPad: int = 0, rightPad: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getBotPad(self: N2D2.PaddingCell) int
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getLeftPad(self: N2D2.PaddingCell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getRightPad(self: N2D2.PaddingCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTopPad(self: N2D2.PaddingCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_float

class N2D2.PoolCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_float, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_double

class N2D2.PoolCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_double, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_CUDA_float

class N2D2.PoolCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_CUDA_double

class N2D2.PoolCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_EXT_CUDA_float

class N2D2.PoolCell_Frame_EXT_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_EXT_CUDA_float, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

PoolCell_Frame_EXT_CUDA_double

class N2D2.PoolCell_Frame_EXT_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.PoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.PoolCell_Frame_EXT_CUDA_double, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.PoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getPaddingX(self: N2D2.PoolCell) int
getPaddingY(self: N2D2.PoolCell) int
getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPoolHeight(self: N2D2.PoolCell) int
getPoolWidth(self: N2D2.PoolCell) int
getPooling(self: N2D2.PoolCell) N2D2::PoolCell::Pooling
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getStrideX(self: N2D2.PoolCell) int
getStrideY(self: N2D2.PoolCell) int
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ProposalCell_Frame

class N2D2.ProposalCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ProposalCell_Frame, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, nbOutputs: int, nbProposals: int, scoreIndex: int = 0, IoUIndex: int = 5, isNms: bool = False, meansFactor: List[float] = [], stdFactor: List[float] = [], numParts: List[int] = [], numTemplates: List[int] = []) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ProposalCell_Frame_CUDA

class N2D2.ProposalCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ProposalCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, nbOutputs: int, nbProposals: int, scoreIndex: int = 0, IoUIndex: int = 5, isNms: bool = False, meansFactor: List[float] = [], stdFactor: List[float] = [], numParts: List[int] = [], numTemplates: List[int] = []) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ROIPoolingCell_Frame

class N2D2.ROIPoolingCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ROIPooling

Members:

Max

Average

Bilinear

BilinearTF

__init__(self: N2D2.ROIPoolingCell.ROIPooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ROIPoolingCell_Frame, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, outputsWidth: int, outputsHeight: int, nbOutputs: int, pooling: N2D2.ROIPoolingCell.ROIPooling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ROIPoolingCell_Frame_CUDA

class N2D2.ROIPoolingCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ROIPooling

Members:

Max

Average

Bilinear

BilinearTF

__init__(self: N2D2.ROIPoolingCell.ROIPooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ROIPoolingCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, sp: N2D2.StimuliProvider, outputsWidth: int, outputsHeight: int, nbOutputs: int, pooling: N2D2.ROIPoolingCell.ROIPooling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

RPCell_Frame

class N2D2.RPCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.RPCell_Frame, deepNet: N2D2.DeepNet, name: str, nbAnchors: int, nbProposals: int, scoreIndex: int = 0, IoUIndex: int = 5) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

RPCell_Frame_CUDA

class N2D2.RPCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.RPCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, nbAnchors: int, nbProposals: int, scoreIndex: int = 0, IoUIndex: int = 5) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ResizeCell_Frame

class N2D2.ResizeCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ResizeMode

Members:

Bilinear

BilinearTF

NearestNeighbor

__init__(self: N2D2.ResizeCell.ResizeMode, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ResizeCell_Frame, deepNet: N2D2.DeepNet, name: str, outputsWidth: int, outputsHeight: int, nbOutputs: int, resizeMode: N2D2.ResizeCell.ResizeMode) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMode(self: N2D2.ResizeCell) N2D2::ResizeCell::ResizeMode
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getResizeOutputHeight(self: N2D2.ResizeCell) int
getResizeOutputWidth(self: N2D2.ResizeCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.ResizeCell) str
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ResizeCell_Frame_CUDA

class N2D2.ResizeCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class ResizeMode

Members:

Bilinear

BilinearTF

NearestNeighbor

__init__(self: N2D2.ResizeCell.ResizeMode, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ResizeCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, outputsWidth: int, outputsHeight: int, nbOutputs: int, resizeMode: N2D2.ResizeCell.ResizeMode) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getMode(self: N2D2.ResizeCell) N2D2::ResizeCell::ResizeMode
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getResizeOutputHeight(self: N2D2.ResizeCell) int
getResizeOutputWidth(self: N2D2.ResizeCell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.ResizeCell) str
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ScalingCell_Frame_float

class N2D2.ScalingCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ScalingCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, scaling: N2D2.Scaling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaling(self: N2D2.ScalingCell) N2D2.Scaling
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ScalingCell_Frame_double

class N2D2.ScalingCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ScalingCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, scaling: N2D2.Scaling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaling(self: N2D2.ScalingCell) N2D2.Scaling
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ScalingCell_Frame_CUDA_float

class N2D2.ScalingCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ScalingCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, scaling: N2D2.Scaling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaling(self: N2D2.ScalingCell) N2D2.Scaling
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ScalingCell_Frame_CUDA_double

class N2D2.ScalingCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ScalingCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, scaling: N2D2.Scaling) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getScaling(self: N2D2.ScalingCell) N2D2.Scaling
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

SoftmaxCell_Frame_float

class N2D2.SoftmaxCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.SoftmaxCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, withLoss: bool = False, groupSize: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.SoftmaxCell_Frame_float) None
checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getGroupSize(self: N2D2.SoftmaxCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWithLoss(self: N2D2.SoftmaxCell) bool
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.SoftmaxCell_Frame_float, inference: bool = False) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWithLoss(self: N2D2.SoftmaxCell, withLoss: bool) None
update(self: N2D2.SoftmaxCell_Frame_float) None

SoftmaxCell_Frame_double

class N2D2.SoftmaxCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.SoftmaxCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, withLoss: bool = False, groupSize: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.SoftmaxCell_Frame_double) None
checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getGroupSize(self: N2D2.SoftmaxCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWithLoss(self: N2D2.SoftmaxCell) bool
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.SoftmaxCell_Frame_double, inference: bool = False) None
save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWithLoss(self: N2D2.SoftmaxCell, withLoss: bool) None
update(self: N2D2.SoftmaxCell_Frame_double) None

SoftmaxCell_Frame_CUDA_float

class N2D2.SoftmaxCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.SoftmaxCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, withLoss: bool = False, groupSize: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getGroupSize(self: N2D2.SoftmaxCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWithLoss(self: N2D2.SoftmaxCell) bool
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWithLoss(self: N2D2.SoftmaxCell, withLoss: bool) None
update(self: N2D2.Cell_Frame_Top) None

SoftmaxCell_Frame_CUDA_double

class N2D2.SoftmaxCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.SoftmaxCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, withLoss: bool = False, groupSize: int = 0) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getGroupSize(self: N2D2.SoftmaxCell) int
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

getWithLoss(self: N2D2.SoftmaxCell) bool
importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setWithLoss(self: N2D2.SoftmaxCell, withLoss: bool) None
update(self: N2D2.Cell_Frame_Top) None

TargetBiasCell_Frame_float

class N2D2.TargetBiasCell_Frame_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TargetBiasCell_Frame_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, bias: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

TargetBiasCell_Frame_double

class N2D2.TargetBiasCell_Frame_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TargetBiasCell_Frame_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, bias: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_double) str
getPyModel(self: N2D2.Cell_Frame_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_double, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

TargetBiasCell_Frame_CUDA_float

class N2D2.TargetBiasCell_Frame_CUDA_float
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TargetBiasCell_Frame_CUDA_float, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, bias: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

TargetBiasCell_Frame_CUDA_double

class N2D2.TargetBiasCell_Frame_CUDA_double
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TargetBiasCell_Frame_CUDA_double, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, bias: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_double, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_double) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_double) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_double) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_double, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_double) str
getPyModel(self: N2D2.Cell_Frame_CUDA_double) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_double, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_double, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_double, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_double, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_double) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_double, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ThresholdCell_Frame

class N2D2.ThresholdCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ThresholdCell_Frame, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, threshold: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

ThresholdCell_Frame_CUDA

class N2D2.ThresholdCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.ThresholdCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, threshold: float) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

TransformationCell_Frame

class N2D2.TransformationCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TransformationCell_Frame, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, transformation: N2D2.Transformation) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTransformation(self: N2D2.TransformationCell) N2D2.Transformation
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

TransformationCell_Frame_CUDA

class N2D2.TransformationCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.TransformationCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, nbOutputs: int, transformation: N2D2.Transformation) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getTransformation(self: N2D2.TransformationCell) N2D2.Transformation
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

UnpoolCell_Frame

class N2D2.UnpoolCell_Frame
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.UnpoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.UnpoolCell_Frame, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.UnpoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_float) str
getPyModel(self: N2D2.Cell_Frame_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_float, diffInput: N2D2.Tensor_float) None
setDiffInputsValid(self: N2D2.Cell_Frame_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_Top, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

UnpoolCell_Frame_CUDA

class N2D2.UnpoolCell_Frame_CUDA
class FreeParametersType

Members:

Additive

Multiplicative

All

__init__(self: N2D2.Cell.FreeParametersType, value: int) None
property name
class Pooling

Members:

Max

Average

__init__(self: N2D2.UnpoolCell.Pooling, value: int) None
property name
class Signals

Members:

In

Out

InOut

__init__(self: N2D2.Cell_Frame_Top.Signals, value: int) None
property name
__init__(self: N2D2.UnpoolCell_Frame_CUDA, deepNet: N2D2.DeepNet, name: str, poolDims: List[int], nbOutputs: int, strideDims: List[int] = [1, 1], paddingDims: List[int] = [0, 0], pooling: N2D2.UnpoolCell.Pooling = <Pooling.Max: 0>, activation: N2D2.Activation = None) None
addInput()

Connect an input filter from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • channel (int) – Channel number in the environment

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int) – Width

  • height (int) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map and the cell output maps (size of the vector = number of output maps in the cell)

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

Connect an input cell to the cell

Parameters:
  • cell (N2D2.Cell) – Pointer to the input cell

  • mapping (N2D2.Tensor_bool, optional) – Connection between the input cell output maps (input channels) and the cell output maps (size of the matrix = number of output maps in the cell [cols] x number of input cell output maps (input channels) [rows])

Connect an input cell to the cell

Parameters:
  • cell – Pointer to the input cell

  • x0 (int) – Left offset

  • y0 (int) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

addInputBis(self: N2D2.Cell_Frame_Top, inputs: N2D2.BaseTensor, diffOutputs: N2D2.BaseTensor) None
addLinkInput(*args, **kwargs)

Overloaded function.

  1. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. addLinkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

addMultiscaleInput(self: N2D2.Cell, sp: N2D2::HeteroStimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0, mapping: N2D2.Tensor_bool = <N2D2.Tensor_bool object at 0x7f6bfd48ad70>) None

Connect all the input maps from the environment to the cell

Parameters:
  • sp (N2D2.StimuliProvider) – N2D2 StimuliProvider object reference

  • x0 (int, optional) – Left offset

  • y0 (int, optional) – Top offset

  • width (int, optional) – Width

  • height (int, optional) – Height

  • mapping (N2D2.Tensor_bool, optional) – Connection between the environment map filters and the cell output maps (size of the matrix = number of output maps in the cell [cols] x total number of filters in the environment [rows])

applyLoss(self: N2D2.Cell_Frame_CUDA_float, targetVal: float, defaultVal: float) float
backPropagate(self: N2D2.Cell_Frame_Top) None

Back propagation of the error

checkGradient(self: N2D2.Cell_Frame_Top, epsilon: float, maxError: float) None
clearInputTensors(self: N2D2.Cell_Frame_CUDA_float) None
clearInputs()

Clear input Cells

clearOutputTensors(self: N2D2.Cell_Frame_CUDA_float) None
exportActivationParameters(self: N2D2.Cell, fileName: str) None

Export activation parameters to a file

Parameters:

fileName (str) – Source file

exportFreeParameters(self: N2D2.Cell, fileName: str) None

Export cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

exportQuantFreeParameters(self: N2D2.Cell, fileName: str) None

Export quantized cell free parameters to a file, in ASCII format compatible between the different cell models

Parameters:

fileName (str) – Destination file

getActivation(self: N2D2.Cell_Frame_Top) N2D2.Activation
getAssociatedDeepNet(self: N2D2.Cell) N2D2.DeepNet
getChildrenCells(self: N2D2.Cell) List[N2D2.Cell]
getDiffInputs(self: N2D2.Cell_Frame_CUDA_float) N2D2.BaseTensor
getDiffOutputs(self: N2D2.Cell_Frame_CUDA_float, index: int = 0) N2D2.BaseTensor
getInputs(self: N2D2.Cell_Frame_Top, index: int = 0) N2D2.BaseTensor
getInputsDims(self: N2D2.Cell) List[int]
getInputsSize(self: N2D2.Cell) int
getMapping(self: N2D2.Cell) N2D2.Tensor_bool
getMaxOutput(self: N2D2.Cell_Frame_Top, batchPos: int = 0) int
getName(self: N2D2.Cell) str

Get the cell name

getNbChannels(self: N2D2.Cell) int
getNbOutputs(self: N2D2.Cell) int

Returns number of output maps in the cell (or number of outputs for 1D cells)

getOutputs(*args, **kwargs)

Overloaded function.

  1. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

  2. getOutputs(self: N2D2.Cell_Frame_Top) -> N2D2.BaseTensor

getOutputsHeight(self: N2D2.Cell) int

Returns cell output maps height (returns 1 for 1D cells)

getOutputsWidth(self: N2D2.Cell) int

Returns cell output maps width (returns 1 for 1D cells)

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getParentsCells(self: N2D2.Cell) List[N2D2.Cell]
getPyDataType(self: N2D2.Cell_Frame_CUDA_float) str
getPyModel(self: N2D2.Cell_Frame_CUDA_float) str
getQuantizedNbBits(self: N2D2.Cell) int
getStats(self: N2D2.Cell, stats: N2D2.Stats) None
getType(self: N2D2.Cell) str

Get basic cell type

importActivationParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load activation parameters from a file

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

importFreeParameters(self: N2D2.Cell, fileName: str, ignoreNotExists: bool = False) None

Load cell free parameters from a file, in ASCII format compatible between the different cell models

Parameters:
  • fileName (str) – Source file

  • ignoreNotExists (bool, optional) – If true, don’t throw an error if the file doesn’t exist

initialize(self: N2D2.Cell) None

Initialize the state of the cell (e.g. weights random initialization)

initializeDataDependent(self: N2D2.Cell) None
initializeParameters(self: N2D2.Cell_Frame_CUDA_float, nbInputChannels: int, nbInputs: int) None
linkInput(*args, **kwargs)

Overloaded function.

  1. linkInput(self: N2D2.Cell_Frame_CUDA_float, cell: N2D2.Cell) -> None

  2. linkInput(self: N2D2.Cell_Frame_CUDA_float, sp: N2D2.StimuliProvider, x0: int = 0, y0: int = 0, width: int = 0, height: int = 0) -> None

load(self: N2D2.Cell, dirName: str) None

Load cell configuration and free parameters from a directory

Parameters:

dirName (str) – Source directory

propagate(self: N2D2.Cell_Frame_Top, inference: bool = False) None

Forward propagation

param inference:

If set to False we are in training mode else we are in inference mode

type inference:

bool, optional

save(self: N2D2.Cell, dirName: str) None

Save cell configuration and free parameters to a directory

Parameters:

dirName (str) – Destination directory

saveFreeParameters(self: N2D2.Cell, fileName: str) None
setActivation(self: N2D2.Cell_Frame_Top, activation: N2D2.Activation) None
setDiffInputs(self: N2D2.Cell_Frame_CUDA_float, diffInput: N2D2.BaseTensor) None
setDiffInputsValid(self: N2D2.Cell_Frame_CUDA_float) None
setMapping(self: N2D2.Cell, mapping: N2D2.Tensor_bool) None
setOutputErrors(self: N2D2.Cell_Frame_Top, errors: N2D2.BaseTensor) None
setOutputTarget(self: N2D2.Cell_Frame_CUDA_float, targets: N2D2.Tensor_int) None
setOutputTargets(self: N2D2.Cell_Frame_Top, targets: N2D2.BaseTensor) None
setParameter(self: N2D2.Parameterizable, name: str, value: str) None
update(self: N2D2.Cell_Frame_Top) None

Filler

class N2D2.Filler
__init__(*args, **kwargs)
getType(self: N2D2.Filler) str

Activation

Introduction

Activation functions in N2D2 are passed as arguments to initialize N2D2.Cell.

tanh = N2D2.TanhActivation_Frame_float()

Activation

Activation

class N2D2.Activation

Virtual class that is inherited by other Activation classes.

__init__(*args, **kwargs)
getActivationScaling(self: N2D2.Activation) N2D2.Scaling
getQuantizer(self: N2D2.Activation) N2D2::QuantizerActivation
getType(self: N2D2.Activation) str
setActivationScaling(self: N2D2.Activation, scaling: N2D2.Scaling) None
setQuantizer(self: N2D2.Activation, quantizer: N2D2::QuantizerActivation) None

LinearActivation

class N2D2.LinearActivation
__init__(*args, **kwargs)
getClipping(self: N2D2.LinearActivation) float

RectifierActivation

class N2D2.RectifierActivation
__init__(*args, **kwargs)
getClipping(self: N2D2.RectifierActivation) float
getLeakSlope(self: N2D2.RectifierActivation) float

TanhActivation

class N2D2.TanhActivation
__init__(*args, **kwargs)
getAlpha(self: N2D2.TanhActivation) float

SwishActivation

class N2D2.SwishActivation
__init__(*args, **kwargs)

SaturationActivation

class N2D2.SaturationActivation
__init__(*args, **kwargs)

LogisticActivation

class N2D2.LogisticActivation
__init__(*args, **kwargs)

SoftplusActivation

class N2D2.SoftplusActivation
__init__(*args, **kwargs)

Activation_Frame

LinearActivation_Frame

class N2D2.LinearActivation_Frame_float
__init__(self: N2D2.LinearActivation_Frame_float) None
class N2D2.LinearActivation_Frame_double
__init__(self: N2D2.LinearActivation_Frame_double) None
class N2D2.LinearActivation_Frame_CUDA_float
__init__(self: N2D2.LinearActivation_Frame_CUDA_float) None
class N2D2.LinearActivation_Frame_CUDA_double
__init__(self: N2D2.LinearActivation_Frame_CUDA_double) None

RectifierActivation_Frame

class N2D2.RectifierActivation_Frame_float
__init__(self: N2D2.RectifierActivation_Frame_float) None
class N2D2.RectifierActivation_Frame_double
__init__(self: N2D2.RectifierActivation_Frame_double) None
class N2D2.RectifierActivation_Frame_CUDA_float
__init__(self: N2D2.RectifierActivation_Frame_CUDA_float) None
class N2D2.RectifierActivation_Frame_CUDA_double
__init__(self: N2D2.RectifierActivation_Frame_CUDA_double) None

TanhActivation_Frame

class N2D2.TanhActivation_Frame_float
__init__(self: N2D2.TanhActivation_Frame_float) None
class N2D2.TanhActivation_Frame_double
__init__(self: N2D2.TanhActivation_Frame_double) None
class N2D2.TanhActivation_Frame_CUDA_float
__init__(self: N2D2.TanhActivation_Frame_CUDA_float) None
class N2D2.TanhActivation_Frame_CUDA_double
__init__(self: N2D2.TanhActivation_Frame_CUDA_double) None

SwishActivation_Frame

class N2D2.SwishActivation_Frame_float
__init__(self: N2D2.SwishActivation_Frame_float) None
class N2D2.SwishActivation_Frame_double
__init__(self: N2D2.SwishActivation_Frame_double) None
class N2D2.SwishActivation_Frame_CUDA_float
__init__(self: N2D2.SwishActivation_Frame_CUDA_float) None
class N2D2.SwishActivation_Frame_CUDA_double
__init__(self: N2D2.SwishActivation_Frame_CUDA_double) None

Solver

class N2D2.Solver
__init__(*args, **kwargs)
getType(self: N2D2.Solver) str

Target

Introduction

A N2D2.Target is associated to a N2D2.Cell, it define the output of the network. The computation of the loss and other tools to compute score such as the confusion matrix are also computed with this class.

To train a neural network you need to use N2D2.Target.provideTargets() then to N2D2.cell.propagate() then N2D2.Target.process() and finally N2D2.Cell.backpropagate(). (See the MNIST example.)

class N2D2.Target
__init__(self: N2D2.Target, name: str, cell: N2D2::Cell, sp: N2D2.StimuliProvider, targetValue: float = 1.0, defaultValue: float = 0.0, targetTopN: int = 1, labelsMapping: str = '', createMissingLabels: bool = False) None
clear(self: N2D2.Target, set: N2D2::Database::StimuliSet) None
getCell(self: N2D2.Target) N2D2::Cell
getDefaultTarget(self: N2D2.Target) int
getDefaultValue(self: N2D2.Target) float
getEstimatedLabel(self: N2D2.Target, roi: N2D2::ROI, batchPos: int = 0, values: float = 0) Tuple[int, float]
getEstimatedLabels(*args, **kwargs)

Overloaded function.

  1. getEstimatedLabels(self: N2D2.Target, dev: int = -1) -> N2D2::CudaTensor<int>

  2. getEstimatedLabels(self: N2D2.Target, roi: N2D2::ROI, batchPos: int = 0, values: float = 0) -> N2D2::CudaTensor<float>

getEstimatedLabelsValue(self: N2D2.Target, dev: int = -1) N2D2::CudaTensor<float>
getLabelTarget(self: N2D2.Target, label: int) int
getLoss(self: N2D2.Target) List[float]
getName(self: N2D2.Target) str
getNbTargets(self: N2D2.Target) int
getStimuliProvider(self: N2D2.Target) N2D2.StimuliProvider
getTargetLabels(self: N2D2.Target, output: int) List[int]
getTargetLabelsName(self: N2D2.Target) List[str]
getTargetTopN(self: N2D2.Target) int
getTargetValue(self: N2D2.Target) float
getType(self: N2D2.Target) str
labelsMapping(self: N2D2.Target, fileName: str, createMissingLabels: bool = False) None
log(self: N2D2.Target, fileName: str, set: N2D2::Database::StimuliSet) None
logEstimatedLabels(self: N2D2.Target, dirName: str) None
logEstimatedLabelsJSON(self: N2D2.Target, dirName: str, fileName: str = '', xOffset: int = 0, yOffset: int = 0, append: bool = False) None
logLabelsLegend(self: N2D2.Target, fileName: str) None
logLabelsMapping(self: N2D2.Target, fileName: str, withStats: bool = False) None
process(self: N2D2.Target, set: N2D2::Database::StimuliSet) None

Apply the loss to the cell the target is bind to.

Parameters:

set (N2D2.Database.StimuliSet) – Set of stimuli

provideTargets(self: N2D2.Target, set: N2D2::Database::StimuliSet) None

Set the output target of a cell. Also create the mapping if labelsMapping option is defined.

Parameters:

set (N2D2.Database.StimuliSet) – Set of stimuli

setDefaultTarget(self: N2D2.Target, output: int) None
setLabelTarget(self: N2D2.Target, label: int, output: int) None
setMaskLabelTarget(self: N2D2.Target, target: N2D2.Target) None
setStimuliProvider(self: N2D2.Target, sp: N2D2.StimuliProvider) None

Databases

Introduction:

N2D2 allow you to import default dataset or to load your own dataset. This can be done suing Database objects.

Download datasets:

To import Data you can use a python Script situated in ./tools/install/install_dataset.py.

This script will download the data in /local/$USER/n2d2_data/. You can change this path with the environment variable N2D2_data.

Once the dataset downloaded, you can load it with the appropriate class. Here is an example of the loading of the MNIST dataset :

database = N2D2.MNIST_IDX_Database()
database.load(path)

In this example, the data are located in the folder path.

Database:

Database

class N2D2.Database

Database specifications:

  • Genericity: load image and sound, 1D, 2D or 3D data

  • Associate a label for each data point or global to the stimulus, 1D or 2D labels

  • ROIs handling:

  • Convert ROIs to data point labels

  • Extract one or multiple ROIs from an initial dataset to create as many corresponding stimuli

class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Database, loadDataInMemory: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

MNIST_IDX_Database

class N2D2.MNIST_IDX_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.MNIST_IDX_Database, validation: float = 0.0) -> None

  2. __init__(self: N2D2.MNIST_IDX_Database, dataPath: str, labelPath: str = ‘’, extractROIs: bool = False, validation: float = 0.0) -> None

getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

Actitracker_Database

class N2D2.Actitracker_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Actitracker_Database, learn: float = 0.6, validation: float = 0.2, useUnlabeledForTest: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

AER_Database

class N2D2.AER_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(*args, **kwargs)
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

Caltech101_DIR_Database

class N2D2.Caltech101_DIR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Caltech101_DIR_Database, learn: float, validation: float = 0.0, incClutter: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

Caltech256_DIR_Database

class N2D2.Caltech256_DIR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Caltech256_DIR_Database, learn: float, validation: float = 0.0, incClutter: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

CaltechPedestrian_Database

class N2D2.CaltechPedestrian_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.CaltechPedestrian_Database, validation: float = 0.0, singleLabel: bool = True, incAmbiguous: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

CelebA_Database

class N2D2.CelebA_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.CelebA_Database, inTheWild: bool, withLandmarks: bool, withPartitioning: bool = True, learn: float = 1.0, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

CIFAR_Database

class N2D2.CIFAR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(*args, **kwargs)
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

CKP_Database

class N2D2.CKP_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.CKP_Database, learn: float, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

DIR_Database

class N2D2.DIR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.DIR_Database, loadDataInMemory: bool = False) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

GTSRB_DIR_Database

class N2D2.GTSRB_DIR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.GTSRB_DIR_Database, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

getValidation(self: N2D2.GTSRB_DIR_Database) float
load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

GTSDB_DIR_Database

class N2D2.GTSDB_DIR_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.GTSDB_DIR_Database, learn: float, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

ILSVRC2012_Database

class N2D2.ILSVRC2012_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.ILSVRC2012_Database, learn: float, useValidationForTest: bool = True, backgroundClass: bool = False) None
getBackgroundClass(self: N2D2.ILSVRC2012_Database) bool
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getLearn(self: N2D2.ILSVRC2012_Database) float
getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

getUseValidationForTest(self: N2D2.ILSVRC2012_Database) bool
load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

IDX_Database

class N2D2.IDX_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.IDX_Database, loadDataInMemory: bool = True) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

IMDBWIKI_Database

class N2D2.IMDBWIKI_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.IMDBWIKI_Database, WikiSet: bool, IMDBSet: bool, CropFrame: bool, useNameAsLabel: bool, learn: float, validation: float) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

KITTI_Database

class N2D2.KITTI_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.KITTI_Database, learn: float) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

KITTI_Object_Database

class N2D2.KITTI_Object_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.KITTI_Object_Database, learn: float) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

KITTI_Road_Database

class N2D2.KITTI_Road_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.KITTI_Road_Database, learn: float) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

LITISRouen_Database

class N2D2.LITISRouen_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.LITISRouen_Database, learn: float = 0.4, validation: float = 4.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

N_MNIST_Database

class N2D2.N_MNIST_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.N_MNIST_Database, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

DOTA_Database

class N2D2.DOTA_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.DOTA_Database, learn: float, useValidationForTest: bool = True) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

Fashion_MNIST_IDX_Database

class N2D2.Fashion_MNIST_IDX_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Fashion_MNIST_IDX_Database, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

setParameter(self: N2D2.Parameterizable, name: str, value: str) None

FDDB_Database

class N2D2.FDDB_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.FDDB_Database, learn: float, validation: float = 0.0) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

Daimler_Database

class N2D2.Daimler_Database
class StimuliSet

Members:

Learn

Validation

Test

Unpartitioned

__init__(self: N2D2.Database.StimuliSet, value: int) None
property name
class StimuliSetMask

Members:

LearnOnly

ValidationOnly

TestOnly

NoLearn

NoValidation

NoTest

All

__init__(self: N2D2.Database.StimuliSetMask, value: int) None
property name
__init__(self: N2D2.Daimler_Database, learn: float, validation: float, test: float, fully: bool) None
getLabelName(self: N2D2.Database, label: int) str

Load data.

Parameters:

label (int) – Label index.

getNbStimuli()

Returns the total number of loaded stimuli.

Returns:

Number of stimuli

Return type:

int

Returns the number of stimuli in one stimuli set.

param set:

Set of stimuli

type set:

N2D2.Database.StimuliSet

return:

Number of stimuli in the set

rtype:

int

getParameterAndType(self: N2D2.Parameterizable, name: str) Tuple[str, str]
getParameters(self: N2D2.Parameterizable) Dict[str, str]
getStimulusLabel()

Returns the label of a stimuli.

Parameters:

set (N2D2.Database.StimulusID) – id of stimuli

Returns:

Label of stimuli

Return type:

int

Returns the label of a stimuli.

Parameters:
Returns:

Label of stimuli

Return type:

int

load(self: N2D2.Database, dataPath: str, labelPath: str = '', extractROIs: bool = False) None

Load data.

Parameters:
  • dataPath (str) – Path to the dataset file.

  • labelPath (str, optional) – Path to the label file.

  • extractROIs (bool, optional) – If True extract ROI

loadDir(self: N2D2.DIR_Database, dataPath: str, depth: int = 0, labelName: str = '', labelDepth: int = 0) None
Parameters:
  • dataPath (str) – path to the data

  • depth (int) – depth = 0: load stimuli only from the current directory (dirPath); depth = 1: load stimuli from dirPath and stimuli contained in the sub-directories of dirPath; depth < 0: load stimuli recursively from dirPath and all its sub-directories

  • labelName (str) – path to the data

  • labelDepth (int) – labelDepth = -1: no label for all stimuli (label ID = -1); labelDepth = 0: uses @p labelName string for all stimuli; labelDepth = 1: uses @p labelName string for stimuli in the current; directory (dirPath) and @p labelName + sub-directory name for stimuli in the sub-directories

setIgnoreMasks(self: N2D2.DIR_Database, ignoreMasks: List[str]) None
Parameters:

ignoreMasks (list) – space-separated list of mask strings to ignore. If any is present in a file path, the file gets ignored. The usual * and + wildcards are allowed.

setParameter(self: N2D2.Parameterizable, name: str, value: str) None
setValidExtensions(self: N2D2.DIR_Database, validExtensions: List[str]) None

StimuliProvider

class N2D2.StimuliProvider

StimuliProvider is a class that acts as a data loader for the neural network.

__init__(self: N2D2.StimuliProvider, database: N2D2::Database, size: List[int], batchSize: int = 1, compositeStimuli: bool = False) None
addOnTheFlyTransformation(self: N2D2.StimuliProvider, transformation: N2D2::CompositeTransformation, setMask: N2D2::Database::StimuliSetMask) None

Add global ON-THE-FLY transformations, before applying any channel transformation. The order of transformations is: global CACHEABLE, then global ON-THE-FLY

addTransformation(self: N2D2.StimuliProvider, transformation: N2D2::CompositeTransformation, setMask: N2D2::Database::StimuliSetMask) None

Add global CACHEABLE transformations, before applying any channel transformation

allBatchsProvided(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet) bool
getBatchSize(self: N2D2.StimuliProvider) int
getData(self: N2D2.StimuliProvider, dev: int = -1) N2D2::CudaTensor<float>
getDataChannel(self: N2D2.StimuliProvider, channel: int, batchPos: int = 0, dev: int = -1) N2D2::CudaTensor<float>
getDatabase(self: N2D2.StimuliProvider) N2D2::Database
getLabelsData(self: N2D2.StimuliProvider, dev: int = -1) N2D2.Tensor_int
getLabelsDataChannel(self: N2D2.StimuliProvider, channel: int, batchPos: int = 0, dev: int = -1) N2D2.Tensor_int
getLabelsROIs(self: N2D2.StimuliProvider, batchPos: int = 0, dev: int = -1) List[N2D2::ROI]
getNbChannels(self: N2D2.StimuliProvider) int
getOnTheFlyTransformation(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet) N2D2::CompositeTransformation
getSize(self: N2D2.StimuliProvider) List[int]
getSizeD(self: N2D2.StimuliProvider) int
getSizeX(self: N2D2.StimuliProvider) int
getSizeY(self: N2D2.StimuliProvider) int
getTransformation(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet) N2D2::CompositeTransformation
isCompositeStimuli(self: N2D2.StimuliProvider) bool
normalizeIntegersStimuli(self: N2D2.StimuliProvider, envCvDepth: int) bool
readBatch(*args, **kwargs)

Overloaded function.

  1. readBatch(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet, startIndex: int) -> None

  2. readBatch(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet) -> None

readRandomBatch(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet) None

Read a whole random batch from the StimuliSet, apply the transformations and set the targets.

setBatch(self: N2D2.StimuliProvider, set: N2D2::Database::StimuliSet, randShuffle: bool, nbMax: int = 0) None
setStreamedLabel(self: N2D2.StimuliProvider, streamedLabel: N2D2.Tensor_int) None

Set Label that is streamed directly to connected Deepnet

setStreamedTensor(self: N2D2.StimuliProvider, streamedTensor: N2D2::CudaTensor<float>) None

Set Tensor that is streamed directly to connected Deepnet

streamBatch(self: N2D2.StimuliProvider, startIndex: int = -1, dev: int = -1) None

Transformation

Introduction

In order to apply transformation to a dataset, we use the transformation object.

Creation of different Transformation object.

dist = N2D2.DistortionTransformation()
dist.setParameter("ElasticGaussianSize", "21")
dist.setParameter("ElasticSigma", "6.0")
dist.setParameter("ElasticScaling", "36.0")
dist.setParameter("Scaling", "10.0")
dist.setParameter("Rotation", "10.0")

padcrop = N2D2.PadCropTransformation(24, 24)

ct = N2D2.CompositeTransformation(padcrop)
ct.push_back(dist)

To apply Transformation to a dataset, we use an object N2D2.StimuliProvider which acts as a data loader.

Transformations

Transformation

class N2D2.Transformation
__init__(*args, **kwargs)
getType(self: N2D2.Transformation) str

DistortionTransformation

class N2D2.DistortionTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.DistortionTransformation) -> None

  2. __init__(self: N2D2.DistortionTransformation, trans: N2D2.DistortionTransformation) -> None

getElasticGaussianSize(self: N2D2.DistortionTransformation) int
getElasticScaling(self: N2D2.DistortionTransformation) float
getElasticSigma(self: N2D2.DistortionTransformation) float
getIgnoreMissingData(self: N2D2.DistortionTransformation) bool
getRotation(self: N2D2.DistortionTransformation) float
getScaling(self: N2D2.DistortionTransformation) float

PadCropTransformation

class N2D2.PadCropTransformation
class BorderType

Members:

ConstantBorder

ReplicateBorder

ReflectBorder

WrapBorder

MinusOneReflectBorder

MeanBorder

__init__(self: N2D2.PadCropTransformation.BorderType, value: int) None
property name
__init__(self: N2D2.PadCropTransformation, width: int, height: int) None
getAdditiveWH(self: N2D2.PadCropTransformation) bool
getBorderType(self: N2D2.PadCropTransformation) N2D2.PadCropTransformation.BorderType
getBorderValue(self: N2D2.PadCropTransformation) List[float]
getHeight(self: N2D2.PadCropTransformation) int
getWidth(self: N2D2.PadCropTransformation) int

CompositeTransformation

class N2D2.CompositeTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.CompositeTransformation) -> None

  2. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.DistortionTransformation) -> None

  3. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.PadCropTransformation) -> None

  4. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.AffineTransformation) -> None

  5. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ChannelExtractionTransformation) -> None

  6. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ColorSpaceTransformation) -> None

  7. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.CompressionNoiseTransformation) -> None

  8. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.DCTTransformation) -> None

  9. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.DFTTransformation) -> None

  10. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.EqualizeTransformation) -> None

  11. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ExpandLabelTransformation) -> None

  12. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.FlipTransformation) -> None

  13. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.WallisFilterTransformation) -> None

  14. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ThresholdTransformation) -> None

  15. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.SliceExtractionTransformation) -> None

  16. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ReshapeTransformation) -> None

  17. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.RescaleTransformation) -> None

  18. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.RangeClippingTransformation) -> None

  19. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.RangeAffineTransformation) -> None

  20. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.RandomAffineTransformation) -> None

  21. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.NormalizeTransformation) -> None

  22. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.MorphologyTransformation) -> None

  23. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.MorphologicalReconstructionTransformation) -> None

  24. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.MagnitudePhaseTransformation) -> None

  25. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.LabelSliceExtractionTransformation) -> None

  26. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.LabelExtractionTransformation) -> None

  27. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.GradientFilterTransformation) -> None

  28. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.ApodizationTransformation) -> None

  29. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.FilterTransformation) -> None

  30. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.RandomResizeCropTransformation) -> None

  31. __init__(self: N2D2.CompositeTransformation, transformation: N2D2.CustomTransformation) -> None

push_back(*args, **kwargs)

Overloaded function.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.CompositeTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.DistortionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.PadCropTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.AffineTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ChannelExtractionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ColorSpaceTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.CompressionNoiseTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.DCTTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.DFTTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.EqualizeTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ExpandLabelTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.FlipTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.WallisFilterTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ThresholdTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.SliceExtractionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ReshapeTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.RescaleTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.RangeClippingTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.RangeAffineTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.RandomAffineTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.NormalizeTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.MorphologyTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.MorphologicalReconstructionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.MagnitudePhaseTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.LabelSliceExtractionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.LabelExtractionTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.GradientFilterTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.ApodizationTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.FilterTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.RandomResizeCropTransformation) -> None

Add a transformation to the list of transformation.

  1. push_back(self: N2D2.CompositeTransformation, arg0: N2D2.CustomTransformation) -> None

Add a transformation to the list of transformation.

size(self: N2D2.CompositeTransformation) int

AffineTransformation

class N2D2.AffineTransformation
class Operator

Members:

Plus

Minus

Multiplies

Divides

__init__(self: N2D2.AffineTransformation.Operator, value: int) None
property name
__init__(self: N2D2.AffineTransformation, firstOperator: N2D2.AffineTransformation.Operator, firstValue: str, secondOperator: N2D2.AffineTransformation.Operator = <Operator.Plus: 0>, secondValue: str = '') None

ChannelExtractionTransformation

class N2D2.ChannelExtractionTransformation
class Channel

Members:

Red

Green

Blue

Hue

Saturation

Value

Gray

Y

Cb

Cr

__init__(self: N2D2.ChannelExtractionTransformation.Channel, value: int) None
property name
__init__(self: N2D2.ChannelExtractionTransformation, channel: N2D2.ChannelExtractionTransformation.Channel) None
getChannel(self: N2D2.ChannelExtractionTransformation) N2D2.ChannelExtractionTransformation.Channel

ColorSpaceTransformation

class N2D2.ColorSpaceTransformation
class ColorSpace

Members:

BGR

RGB

HSV

HLS

YCrCb

CIELab

CIELuv

RGB_to_BGR

RGB_to_HSV

RGB_to_HLS

RGB_to_YCrCb

RGB_to_CIELab

RGB_to_CIELuv

HSV_to_BGR

HSV_to_RGB

HLS_to_BGR

HLS_to_RGB

YCrCb_to_BGR

YCrCb_to_RGB

CIELab_to_BGR

CIELab_to_RGB

CIELuv_to_BGR

CIELuv_to_RGB

__init__(self: N2D2.ColorSpaceTransformation.ColorSpace, value: int) None
property name
__init__(self: N2D2.ColorSpaceTransformation, colorSpace: N2D2.ColorSpaceTransformation.ColorSpace) None
getColorSpace(self: N2D2.ColorSpaceTransformation) N2D2.ColorSpaceTransformation.ColorSpace

CompressionNoiseTransformation

class N2D2.CompressionNoiseTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.CompressionNoiseTransformation) -> None

  2. __init__(self: N2D2.CompressionNoiseTransformation, trans: N2D2.CompressionNoiseTransformation) -> None

DCTTransformation

class N2D2.DCTTransformation
__init__(self: N2D2.DCTTransformation, twoDimensional: bool = True) None

DFTTransformation

class N2D2.DFTTransformation
__init__(self: N2D2.DFTTransformation, twoDimensional: bool = True) None

EqualizeTransformation

class N2D2.EqualizeTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.EqualizeTransformation) -> None

  2. __init__(self: N2D2.EqualizeTransformation, trans: N2D2.EqualizeTransformation) -> None

ExpandLabelTransformation

class N2D2.ExpandLabelTransformation
__init__(self: N2D2.ExpandLabelTransformation) None

WallisFilterTransformation

class N2D2.WallisFilterTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.WallisFilterTransformation, size: int, mean: float = 0.0, stdDev: float = 1.0) -> None

  2. __init__(self: N2D2.WallisFilterTransformation, trans: N2D2.WallisFilterTransformation) -> None

ThresholdTransformation

class N2D2.ThresholdTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.ThresholdTransformation, threshold: float, otsuMethod: bool = False) -> None

  2. __init__(self: N2D2.ThresholdTransformation, trans: N2D2.ThresholdTransformation) -> None

SliceExtractionTransformation

class N2D2.SliceExtractionTransformation
class BorderType

Members:

ConstantBorder

ReplicateBorder

ReflectBorder

WrapBorder

MinusOneReflectBorder

MeanBorder

__init__(self: N2D2.SliceExtractionTransformation.BorderType, value: int) None
property name
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.SliceExtractionTransformation, width: int, height: int, OffsetX: int = 0, OffsetY: int = 0) -> None

  2. __init__(self: N2D2.SliceExtractionTransformation, trans: N2D2.SliceExtractionTransformation) -> None

getAllowPadding(self: N2D2.SliceExtractionTransformation) bool
getBorderType(self: N2D2.SliceExtractionTransformation) N2D2.SliceExtractionTransformation.BorderType
getBorderValue(self: N2D2.SliceExtractionTransformation) List[float]
getHeight(self: N2D2.SliceExtractionTransformation) int
getOffsetX(self: N2D2.SliceExtractionTransformation) int
getOffsetY(self: N2D2.SliceExtractionTransformation) int
getRandomOffsetX(self: N2D2.SliceExtractionTransformation) bool
getRandomOffsetY(self: N2D2.SliceExtractionTransformation) bool
getRandomRotation(self: N2D2.SliceExtractionTransformation) bool
getRandomRotationRange(self: N2D2.SliceExtractionTransformation) List[float]
getRandomScaling(self: N2D2.SliceExtractionTransformation) bool
getRandomScalingRange(self: N2D2.SliceExtractionTransformation) List[float]
getWidth(self: N2D2.SliceExtractionTransformation) int

ReshapeTransformation

class N2D2.ReshapeTransformation
__init__(self: N2D2.ReshapeTransformation, nbRows: int, nbCols: int = 0, nbChannels: int = 0) None
getNbChannels(self: N2D2.ReshapeTransformation) int
getNbCols(self: N2D2.ReshapeTransformation) int
getNbRows(self: N2D2.ReshapeTransformation) int

RescaleTransformation

class N2D2.RescaleTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.RescaleTransformation, width: int, height: int) -> None

  2. __init__(self: N2D2.RescaleTransformation, trans: N2D2.RescaleTransformation) -> None

getHeight(self: N2D2.RescaleTransformation) int
getKeepAspectRatio(self: N2D2.RescaleTransformation) bool
getResizeToFit(self: N2D2.RescaleTransformation) bool
getWidth(self: N2D2.RescaleTransformation) int

RangeClippingTransformation

class N2D2.RangeClippingTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.RangeClippingTransformation) -> None

  2. __init__(self: N2D2.RangeClippingTransformation, trans: N2D2.RangeClippingTransformation) -> None

RangeAffineTransformation

class N2D2.RangeAffineTransformation
class Operator

Members:

Plus

Minus

Multiplies

Divides

__init__(self: N2D2.RangeAffineTransformation.Operator, value: int) None
property name
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.RangeAffineTransformation, firstOperator: N2D2.RangeAffineTransformation.Operator, firstValue: List[float], secondOperator: N2D2.RangeAffineTransformation.Operator = <Operator.Plus: 0>, secondValue: List[float] = []) -> None

  2. __init__(self: N2D2.RangeAffineTransformation, firstOperator: N2D2.RangeAffineTransformation.Operator, firstValue: float, secondOperator: N2D2.RangeAffineTransformation.Operator = <Operator.Plus: 0>, secondValue: float = 0.0) -> None

  3. __init__(self: N2D2.RangeAffineTransformation, trans: N2D2.RangeAffineTransformation) -> None

getFirstOperator(self: N2D2.RangeAffineTransformation) N2D2.RangeAffineTransformation.Operator
getFirstValue(self: N2D2.RangeAffineTransformation) List[float]
getSecondOperator(self: N2D2.RangeAffineTransformation) N2D2.RangeAffineTransformation.Operator
getSecondValue(self: N2D2.RangeAffineTransformation) List[float]
getTruncate(self: N2D2.RangeAffineTransformation) bool

RandomAffineTransformation

class N2D2.RandomAffineTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.RandomAffineTransformation, gainRange: List[Tuple[float, float]], biasRange: List[Tuple[float, float]] = [], gammaRange: List[Tuple[float, float]] = [], gainVarProb: List[float] = [], biasVarProb: List[float] = [], gammaVarProb: List[float] = []) -> None

  2. __init__(self: N2D2.RandomAffineTransformation, trans: N2D2.RandomAffineTransformation) -> None

NormalizeTransformation

class N2D2.NormalizeTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.NormalizeTransformation) -> None

  2. __init__(self: N2D2.NormalizeTransformation, trans: N2D2.NormalizeTransformation) -> None

MorphologyTransformation

class N2D2.MorphologyTransformation
class Operation

Members:

Erode

Dilate

Opening

Closing

Gradient

TopHat

BlackHat

__init__(self: N2D2.MorphologyTransformation.Operation, value: int) None
property name
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.MorphologyTransformation, operation: N2D2.MorphologyTransformation.Operation, size: int, applyToLabels: bool = False) -> None

  2. __init__(self: N2D2.MorphologyTransformation, trans: N2D2.MorphologyTransformation) -> None

MorphologicalReconstructionTransformation

class N2D2.MorphologicalReconstructionTransformation
class Operation

Members:

ReconstructionByErosion

ReconstructionByDilation

OpeningByReconstruction

ClosingByReconstruction

__init__(self: N2D2.MorphologicalReconstructionTransformation.Operation, value: int) None
property name
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.MorphologicalReconstructionTransformation, operation: N2D2.MorphologicalReconstructionTransformation.Operation, size: int, applyToLabels: bool = False) -> None

  2. __init__(self: N2D2.MorphologicalReconstructionTransformation, trans: N2D2.MorphologicalReconstructionTransformation) -> None

MagnitudePhaseTransformation

class N2D2.MagnitudePhaseTransformation
__init__(self: N2D2.MagnitudePhaseTransformation, logScale: bool = False) None

LabelSliceExtractionTransformation

class N2D2.LabelSliceExtractionTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.LabelSliceExtractionTransformation, width: int, height: int, label: int = -1) -> None

  2. __init__(self: N2D2.LabelSliceExtractionTransformation, trans: N2D2.LabelSliceExtractionTransformation) -> None

LabelExtractionTransformation

class N2D2.LabelExtractionTransformation
__init__(self: N2D2.LabelExtractionTransformation, widths: str, heights: str, label: int = -1, distributions: str = 'Auto') None

GradientFilterTransformation

class N2D2.GradientFilterTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.GradientFilterTransformation, scsale: float = 1.0, delta: float = 0.0, applyToLabels: bool = False) -> None

  2. __init__(self: N2D2.GradientFilterTransformation, trans: N2D2.GradientFilterTransformation) -> None

ApodizationTransformation

class N2D2.ApodizationTransformation
__init__(self: N2D2.ApodizationTransformation, func: N2D2.WindowFunction_double, size: int) None

FilterTransformation

class N2D2.FilterTransformation
__init__(self: N2D2.FilterTransformation, kernel: N2D2.Kernel_double, orientation: float = 0.0) None

FlipTransformation

class N2D2.FlipTransformation
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.FlipTransformation, horizontalFlip: bool = False, verticalFlip: bool = False) -> None

  2. __init__(self: N2D2.FlipTransformation, trans: N2D2.FlipTransformation) -> None

getHorizontalFlip(self: N2D2.FlipTransformation) bool
getRandomHorizontalFlip(self: N2D2.FlipTransformation) bool
getRandomVerticalFlip(self: N2D2.FlipTransformation) bool
getVerticalFlip(self: N2D2.FlipTransformation) bool

Containers

Introduction

N2D2 has his own Tensor implementation.

N2D2.Tensor_float([1, 2, 3])

Tensor can be also be created using numpy.array object.

N2D2.CudaTensor_float(numpy.array([[1.0, 2.0], [3.0, 4.0]]))

Tensor

class N2D2.BaseTensor
__init__(*args, **kwargs)
clear(self: N2D2.BaseTensor) None
dimB(self: N2D2.BaseTensor) int
dimD(self: N2D2.BaseTensor) int
dimX(self: N2D2.BaseTensor) int
dimY(self: N2D2.BaseTensor) int
dimZ(self: N2D2.BaseTensor) int
dims(self: N2D2.BaseTensor) List[int]
empty(self: N2D2.BaseTensor) bool
getType(self: N2D2.BaseTensor) std::type_info
getTypeName(self: N2D2.BaseTensor) str
isValid(self: N2D2.BaseTensor, dev: int = -1) bool
nbDims(self: N2D2.BaseTensor) int
op_assign(self: N2D2.BaseTensor, arg0: N2D2.BaseTensor) N2D2.BaseTensor
reshape(self: N2D2.BaseTensor, dims: List[int]) None
resize(self: N2D2.BaseTensor, dims: List[int]) None
setValid(self: N2D2.BaseTensor, dev: int = -1) None
size(self: N2D2.BaseTensor) int
synchronizeDBasedToH(self: N2D2.BaseTensor) None
synchronizeDToH(self: N2D2.BaseTensor) None
synchronizeDToHBased(self: N2D2.BaseTensor) None
synchronizeHBasedToD(self: N2D2.BaseTensor) None
synchronizeHToD(self: N2D2.BaseTensor) None
synchronizeHToDBased(self: N2D2.BaseTensor) None
class N2D2.Tensor_float
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.Tensor_float) -> None

  2. __init__(self: N2D2.Tensor_float, dims: List[int], value: float = 0.0) -> None

  3. __init__(self: N2D2.Tensor_float, arg0: numpy.ndarray[numpy.float32]) -> None

fill(self: N2D2.Tensor_float, value: float) None
mean(self: N2D2.Tensor_float, valAbs: bool = False) float
sum(self: N2D2.Tensor_float, valAbs: bool = False) float
class N2D2.Tensor_double
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.Tensor_double) -> None

  2. __init__(self: N2D2.Tensor_double, dims: List[int], value: float = 0.0) -> None

  3. __init__(self: N2D2.Tensor_double, arg0: numpy.ndarray[numpy.float64]) -> None

fill(self: N2D2.Tensor_double, value: float) None
mean(self: N2D2.Tensor_double, valAbs: bool = False) float
sum(self: N2D2.Tensor_double, valAbs: bool = False) float
class N2D2.Tensor_bool
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.Tensor_bool) -> None

  2. __init__(self: N2D2.Tensor_bool, dims: List[int], value: bool = False) -> None

fill(self: N2D2.Tensor_bool, value: bool) None
mean(self: N2D2.Tensor_bool, valAbs: bool = False) float
sum(self: N2D2.Tensor_bool, valAbs: bool = False) float

CudaTensor

class N2D2.CudaBaseDeviceTensor
__init__(*args, **kwargs)
getCudaTensor(self: N2D2.CudaBaseDeviceTensor) N2D2::CudaBaseTensor
getType(self: N2D2.CudaBaseDeviceTensor) std::type_info
class N2D2.CudaBaseTensor
__init__(*args, **kwargs)
deviceTensor(self: N2D2.CudaBaseTensor) N2D2.CudaBaseDeviceTensor
hostBased(self: N2D2.CudaBaseTensor) bool
class N2D2.CudaTensor_float
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.CudaTensor_float) -> None

  2. __init__(self: N2D2.CudaTensor_float, dims: List[int], value: float = 0.0) -> None

  3. __init__(self: N2D2.CudaTensor_float, arg0: List[int], arg1: int, arg2: int) -> None

  4. __init__(self: N2D2.CudaTensor_float, arg0: numpy.ndarray[numpy.float32]) -> None

class N2D2.CudaTensor_double
__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: N2D2.CudaTensor_double) -> None

  2. __init__(self: N2D2.CudaTensor_double, dims: List[int], value: float = 0.0) -> None

  3. __init__(self: N2D2.CudaTensor_double, arg0: List[int], arg1: int, arg2: int) -> None

  4. __init__(self: N2D2.CudaTensor_double, arg0: numpy.ndarray[numpy.float64]) -> None