ocean::Filler

Neurocean2023年4月2日大约 5 分钟

ocean::Filler

张量填充器 More...

#include <Filler.hpp>

Public Functions

Name
Filler()
空填充器
Filler(PIFiller filler_)
构造填充器
Filler(const Filler & arg)
拷贝构造
Filler &operator=(const Filler & arg)
赋值构造
Filler(const FillerType & type, const DataType & dataType, const FillerArguments & args)
从数值参数构造填充器
Filler(const FillerType & type, const DataType & dataType, const Arguments & args)
从通用参数构造填充器
Filler(const DataType & dataType)
构建零填充器
Filler(const Tensor & copy)
构建拷贝填充器
Filler(VariableValue & value)
从变量值构建张量填充器
template <typename T >
Filler(T value)
从数值构建张量填充器
template <typename T >
Filler(T min, T max, uint32_t seed =0)
构建均匀分布填充器
Filler(DataType type, float mean, float stddev, uint32_t seed =0)
构建正态分布填充器
virtual~Filler()
析构填充器
const PIFiller &getFiller() const
获取内部填充器指针
voidsetFiller(PIFiller filler)
设置填充器指针
FillermakeZero(const DataType & dataType)
构建零填充器
FillermakeCopy(const Tensor & copy)
构建拷贝填充器
FillermakeConst(VariableValue & value)
从变量值构建张量填充器
template <typename T >
Filler
makeConst(T value)
从数值构建张量填充器
template <typename T >
Filler
makeUniform(T min, T max, uint32_t seed =0)
构建均匀分布填充器
FillermakeLogNormal(DataType type, float mean, float stddev, uint32_t seed =0)
构建正态分布填充器
FillermakeLocalConvolutionFiller(uint32_t receptorField, uint32_t width, uint32_t height, Tensor scaled)
构建局部卷积填充器

Protected Functions

Name
voidmakeFiller(const FillerType & type, const DataType & dataType, const Arguments & args)
从通用参数构造填充器
voidmakeFiller(const FillerType & type, const DataType & dataType, const FillerArguments & args)
从数值参数构造填充器

Protected Attributes

Name
PIFillerfiller
填充器

Detailed Description

class ocean::Filler;

张量填充器

张量填充器统一了张量变量的初始化机制,提供了一种异步填充机制,可以用于初始化或重置张量的内容。

Public Functions Documentation

function Filler

Filler()

空填充器

function Filler

explicit Filler(
    PIFiller filler_
)

构造填充器

Parameters:

Note: 该方法仅被内部模块使用

function Filler

Filler(
    const Filler & arg
)

拷贝构造

Parameters:

function operator=

Filler & operator=(
    const Filler & arg
)

赋值构造

Parameters:

Return:

function Filler

Filler(
    const FillerType & type,
    const DataType & dataType,
    const FillerArguments & args
)

从数值参数构造填充器

Parameters:

function Filler

Filler(
    const FillerType & type,
    const DataType & dataType,
    const Arguments & args
)

从通用参数构造填充器

Parameters:

function Filler

Filler(
    const DataType & dataType
)

构建零填充器

Parameters:

function Filler

Filler(
    const Tensor & copy
)

构建拷贝填充器

Parameters:

function Filler

Filler(
    VariableValue & value
)

从变量值构建张量填充器

Parameters:

function Filler

template <typename T >
Filler(
    T value
)

从数值构建张量填充器

Parameters:

Template Parameters:

function Filler

template <typename T >
Filler(
    T min,
    T max,
    uint32_t seed =0
)

构建均匀分布填充器

Parameters:

Template Parameters:

function Filler

Filler(
    DataType type,
    float mean,
    float stddev,
    uint32_t seed =0
)

构建正态分布填充器

Parameters:

function ~Filler

virtual ~Filler()

析构填充器

function getFiller

const PIFiller & getFiller() const

获取内部填充器指针

Return: 内部填充器指针

function setFiller

void setFiller(
    PIFiller filler
)

设置填充器指针

Parameters:

function makeZero

static Filler makeZero(
    const DataType & dataType
)

构建零填充器

Parameters:

Return: 填充器

function makeCopy

static Filler makeCopy(
    const Tensor & copy
)

构建拷贝填充器

Parameters:

Return: 填充器

function makeConst

static Filler makeConst(
    VariableValue & value
)

从变量值构建张量填充器

Parameters:

Return: 填充器

function makeConst

template <typename T >
static Filler makeConst(
    T value
)

从数值构建张量填充器

Parameters:

Template Parameters:

Return: 填充器

function makeUniform

template <typename T >
static Filler makeUniform(
    T min,
    T max,
    uint32_t seed =0
)

构建均匀分布填充器

Parameters:

Template Parameters:

Return: 填充器

function makeLogNormal

static Filler makeLogNormal(
    DataType type,
    float mean,
    float stddev,
    uint32_t seed =0
)

构建正态分布填充器

Parameters:

Return: 填充器

function makeLocalConvolutionFiller

static Filler makeLocalConvolutionFiller(
    uint32_t receptorField,
    uint32_t width,
    uint32_t height,
    Tensor scaled
)

构建局部卷积填充器

Parameters:

Return: 填充器

Protected Functions Documentation

function makeFiller

void makeFiller(
    const FillerType & type,
    const DataType & dataType,
    const Arguments & args
)

从通用参数构造填充器

Parameters:

function makeFiller

void makeFiller(
    const FillerType & type,
    const DataType & dataType,
    const FillerArguments & args
)

从数值参数构造填充器

Parameters:

Protected Attributes Documentation

variable filler

PIFiller filler;

填充器


Updated on 2022-08-19 at 17:14:26 +0800