unsafe void IOperatorDescriptionMarshal.__MarshalFree(ref IntPtr pDesc)
    {
        var @ref = (__Native *)pDesc;

        InputTensor.__MarshalFree(ref @ref->InputTensor);
        InputGradientTensor.__MarshalFree(ref @ref->InputGradientTensor);
        MeanTensor.__MarshalFree(ref @ref->MeanTensor);
        VarianceTensor.__MarshalFree(ref @ref->VarianceTensor);
        ScaleTensor.__MarshalFree(ref @ref->ScaleTensor);
        OutputGradientTensor.__MarshalFree(ref @ref->OutputGradientTensor);
        OutputScaleGradientTensor.__MarshalFree(ref @ref->OutputScaleGradientTensor);
        OutputBiasGradientTensor.__MarshalFree(ref @ref->OutputBiasGradientTensor);

        UnsafeUtilities.Free(@ref);
    }
Example #2
0
    unsafe void IOperatorDescriptionMarshal.__MarshalFree(ref IntPtr pDesc)
    {
        var @ref = (__Native *)pDesc;

        InputTensor.__MarshalFree(ref @ref->InputTensor);
        MeanTensor.__MarshalFree(ref @ref->MeanTensor);
        VarianceTensor.__MarshalFree(ref @ref->VarianceTensor);
        ScaleTensor.__MarshalFree(ref @ref->ScaleTensor);
        BiasTensor.__MarshalFree(ref @ref->BiasTensor);
        OutputTensor.__MarshalFree(ref @ref->OutputTensor);

        if (FusedActivation != null)
        {
            FusedActivation.Value.__MarshalFree(ref @ref->FusedActivation);
        }

        UnsafeUtilities.Free(@ref);
    }