qubee.calibration.preprocess.NpyPad Class Reference

qubee.calibration.preprocess.NpyPad Class Reference#

Mobilint SDK qb Compiler: qubee.calibration.preprocess.NpyPad Class Reference
Mobilint SDK qb Compiler v0.12.0.0
MCS002-EN
qubee.calibration.preprocess.NpyPad Class Reference

Pad NumPy arrays to a desired shape. More...

Public Member Functions

 __init__ (self, List[int] shape, str padding_type, Optional[float] pad_val=0)
 __call__ (self, np.ndarray data)
 slice_padded_data (self, data)

Public Attributes

 shape = np.array(shape)
str padding_type = padding_type
 pad_val = pad_val

Detailed Description

Pad NumPy arrays to a desired shape.

Parameters
shapelist[int]. Expected output shape after padding.
padding_typestring. Padding mode, either "constant" or "reflect".
pad_valfloat. Fill value when padding_mode is 'constant'. Defaults to 0.

Definition at line 91 of file preprocess.py.

Constructor & Destructor Documentation

◆ __init__()

qubee.calibration.preprocess.NpyPad.__init__ ( self,
List[int] shape,
str padding_type,
Optional[float] pad_val = 0 )

Definition at line 100 of file preprocess.py.

Member Function Documentation

◆ __call__()

qubee.calibration.preprocess.NpyPad.__call__ ( self,
np.ndarray data )

Definition at line 111 of file preprocess.py.

◆ slice_padded_data()

qubee.calibration.preprocess.NpyPad.slice_padded_data ( self,
data )

Definition at line 136 of file preprocess.py.

Member Data Documentation

◆ shape

qubee.calibration.preprocess.NpyPad.shape = np.array(shape)

Definition at line 107 of file preprocess.py.

◆ padding_type

str qubee.calibration.preprocess.NpyPad.padding_type = padding_type

Definition at line 108 of file preprocess.py.

◆ pad_val

qubee.calibration.preprocess.NpyPad.pad_val = pad_val

Definition at line 109 of file preprocess.py.


The documentation for this class was generated from the following file: