public interface MPSCNNGroupNormalizationDataSource extends NSCopying
The MPSCNNGroupNormalizationDataSource protocol declares the methods that an group of MPSCNNGroupNormalization uses to initialize the scale factors (gamma) and bias terms (beta).
| Modifier and Type | Method and Description |
|---|---|
default boolean |
_supportsSecureCoding() |
org.moe.natj.general.ptr.FloatPtr |
beta()
Return a pointer to an array containing the beta terms.
|
default MPSCNNGroupNormalizationDataSource |
copyWithZoneDevice(org.moe.natj.general.ptr.VoidPtr zone,
MTLDevice device)
Optional copy method to create a copy of the data source for use with a new device.
|
default void |
encodeWithCoder(NSCoder aCoder)
Optional NSSecureCoding compatibility.
|
default float |
epsilon()
An optional tiny number to use to maintain numerical stability.
|
org.moe.natj.general.ptr.FloatPtr |
gamma()
Return a pointer to an array containing the gamma terms.
|
default MPSCNNGroupNormalizationDataSource |
initWithCoder(NSCoder aDecoder)
NS_DESIGNATED_INITIALIZER
|
java.lang.String |
label()
A label that is transferred to the group normalization filter at init time
|
long |
numberOfFeatureChannels()
[@property] The number of feature channels that are normalized.
|
long |
numberOfGroups()
[@property] The number of groups used.
|
void |
setNumberOfGroups(long value)
[@property] The number of groups used.
|
copyWithZoneorg.moe.natj.general.ptr.FloatPtr beta()
Must have numberOfFeatureChannels values since scaling is done per feature channel.
default MPSCNNGroupNormalizationDataSource copyWithZoneDevice(org.moe.natj.general.ptr.VoidPtr zone, MTLDevice device)
zone - The NSZone on which to allocate.device - The device where the kernel which uses this data source will be used.default void encodeWithCoder(NSCoder aCoder)
default float epsilon()
output_image = (input_image - mean[c]) * gamma[c] / sqrt(variance[c] + epsilon) + beta[c]; Defalt value if method unavailable: FLT_MIN
org.moe.natj.general.ptr.FloatPtr gamma()
Must have numberOfFeatureChannels values since scaling is done per feature channel.
default MPSCNNGroupNormalizationDataSource initWithCoder(NSCoder aDecoder)
java.lang.String label()
Overridden by a MPSCNNGroupNormalizationNode.label if it is non-nil.
long numberOfFeatureChannels()
long numberOfGroups()
numberOfFeatureChannels/numberOfGroups channels are normalized together.
void setNumberOfGroups(long value)
numberOfFeatureChannels/numberOfGroups channels are normalized together.
default boolean _supportsSecureCoding()