Пример #1
0
 public unsafe MPSCnnBinaryConvolution(IMTLDevice device, IMPSCnnConvolutionDataSource convolutionData, float [] outputBiasTerms, float [] outputScaleTerms, float [] inputBiasTerms, float [] inputScaleTerms, MPSCnnBinaryConvolutionType type, MPSCnnBinaryConvolutionFlags flags)
     : base(NSObjectFlag.Empty)
 {
     fixed(void *outputBiasTermsHandle = outputBiasTerms)
     fixed(void *outputScaleTermsHandle = outputScaleTerms)
     fixed(void *inputBiasTermsHandle   = inputBiasTerms)
     fixed(void *inputScaleTermsHandle  = inputScaleTerms)
     InitializeHandle(InitWithDevice(device, convolutionData, (IntPtr)outputBiasTermsHandle, (IntPtr)outputScaleTermsHandle, (IntPtr)inputBiasTermsHandle, (IntPtr)inputScaleTermsHandle, type, flags));
 }
Пример #2
0
 public MPSCnnBinaryFullyConnectedNode(MPSNNImageNode sourceNode, IMPSCnnConvolutionDataSource weights, float [] outputBiasTerms, float [] outputScaleTerms, float [] inputBiasTerms, float [] inputScaleTerms, MPSCnnBinaryConvolutionType type, MPSCnnBinaryConvolutionFlags flags) : base(NSObjectFlag.Empty)
 {
     unsafe {
         fixed(void *outputBiasTermsHandle = outputBiasTerms)
         fixed(void *outputScaleTermsHandle = outputScaleTerms)
         fixed(void *inputBiasTermsHandle   = inputBiasTerms)
         fixed(void *inputScaleTermsHandle  = inputScaleTerms)
         InitializeHandle(InitWithSource(sourceNode, weights, (IntPtr)outputBiasTermsHandle, (IntPtr)outputScaleTermsHandle, (IntPtr)inputBiasTermsHandle, (IntPtr)inputScaleTermsHandle, type, flags));
     }
 }
Пример #3
0
 public static MPSCnnBinaryConvolutionNode Create(MPSNNImageNode sourceNode, IMPSCnnConvolutionDataSource weights, float [] outputBiasTerms, float [] outputScaleTerms, float [] inputBiasTerms, float [] inputScaleTerms, MPSCnnBinaryConvolutionType type, MPSCnnBinaryConvolutionFlags flags)
 {
     unsafe {
         fixed(void *outputBiasTermsHandle = outputBiasTerms)
         fixed(void *outputScaleTermsHandle = outputScaleTerms)
         fixed(void *inputBiasTermsHandle   = inputBiasTerms)
         fixed(void *inputScaleTermsHandle  = inputScaleTerms)
         return(Create(sourceNode, weights, (IntPtr)outputBiasTermsHandle, (IntPtr)outputScaleTermsHandle, (IntPtr)inputBiasTermsHandle, (IntPtr)inputScaleTermsHandle, type, flags));
     }
 }
Пример #4
0
 static public MPSCnnConvolutionTransposeNode Create(MPSNNImageNode sourceNode, MPSCnnConvolutionStateNode convolutionState, IMPSCnnConvolutionDataSource weights)
 {
     return(null);
 }
Пример #5
0
 public MPSCnnConvolutionTransposeNode(MPSNNImageNode sourceNode, MPSCnnConvolutionStateNode convolutionState, IMPSCnnConvolutionDataSource weights) : base(IntPtr.Zero)
 {
     throw new NotSupportedException();
 }