Interface MPSCNNInstanceNormalizationDataSource
-
- All Superinterfaces:
NSCopying
public interface MPSCNNInstanceNormalizationDataSource extends NSCopying
[@protocol] MPSCNNInstanceNormalizationDataSource The MPSCNNInstanceNormalizationDataSource protocol declares the methods that an instance of MPSCNNInstanceNormalization uses to initialize the scale factors (gamma) and bias terms (beta). API-Since: 11.3
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default boolean_supportsSecureCoding()@Nullable org.moe.natj.general.ptr.FloatPtrbeta()Return a pointer to an array containing the beta terms.default @NotNull MPSCNNInstanceNormalizationDataSourcecopyWithZoneDevice(@Nullable org.moe.natj.general.ptr.VoidPtr zone, @Nullable MTLDevice device)Optional copy method to create a copy of the data source for use with a new device.default voidencodeWithCoder(@NotNull NSCoder aCoder)Optional NSSecureCoding compatibility.default floatepsilon()An optional tiny number to use to maintain numerical stability.@Nullable org.moe.natj.general.ptr.FloatPtrgamma()Return a pointer to an array containing the gamma terms.default @Nullable MPSCNNInstanceNormalizationDataSourceinitWithCoder(@NotNull NSCoder aDecoder)NS_DESIGNATED_INITIALIZER@Nullable java.lang.Stringlabel()A label that is transferred to the instance normalization filter at init time Overridden by a MPSCNNInstanceNormalizationNode.label if it is non-nil.default booleanload_objc()Alerts the data source that the data will be needed soonlongnumberOfFeatureChannels()[@property] The number of feature channels over which to normalize.default voidpurge()Alerts the data source that the data is no longer needed API-Since: 13.0-
Methods inherited from interface apple.foundation.protocol.NSCopying
copyWithZone
-
-
-
-
Method Detail
-
beta
@Nullable @Nullable org.moe.natj.general.ptr.FloatPtr beta()
Return a pointer to an array containing the beta terms.
-
copyWithZoneDevice
@NotNull default @NotNull MPSCNNInstanceNormalizationDataSource copyWithZoneDevice(@Nullable @Nullable org.moe.natj.general.ptr.VoidPtr zone, @Nullable @Nullable MTLDevice device)
Optional copy method to create a copy of the data source for use with a new device.- Parameters:
zone- The NSZone on which to allocate.device- The device where the kernel which uses this data source will be used.- Returns:
- A pointer to a copy of this data source. API-Since: 12.0
-
encodeWithCoder
default void encodeWithCoder(@NotNull @NotNull NSCoder aCoder)Optional NSSecureCoding compatibility.
-
epsilon
default float epsilon()
An optional tiny number to use to maintain numerical stability. output_image = (input_image - mean[c]) * gamma[c] / sqrt(variance[c] + epsilon) + beta[c]; Defalt value if method unavailable: FLT_MIN
-
gamma
@Nullable @Nullable org.moe.natj.general.ptr.FloatPtr gamma()
Return a pointer to an array containing the gamma terms.
-
initWithCoder
@Nullable default @Nullable MPSCNNInstanceNormalizationDataSource initWithCoder(@NotNull @NotNull NSCoder aDecoder)
NS_DESIGNATED_INITIALIZER
-
label
@Nullable @Nullable java.lang.String label()
A label that is transferred to the instance normalization filter at init time Overridden by a MPSCNNInstanceNormalizationNode.label if it is non-nil.
-
load_objc
default boolean load_objc()
Alerts the data source that the data will be needed soon- Returns:
- Returns YES on success. If NO is returned, expect MPS object construction to fail. API-Since: 13.0
-
numberOfFeatureChannels
long numberOfFeatureChannels()
[@property] The number of feature channels over which to normalize.
-
purge
default void purge()
Alerts the data source that the data is no longer needed API-Since: 13.0
-
_supportsSecureCoding
default boolean _supportsSecureCoding()
-
-