Share via


MLCLossLayer.CreateCosineDistanceLoss Method

Definition

Overloads

CreateCosineDistanceLoss(MLCReductionType, MLCTensor)

[Foundation.Export("cosineDistanceLossWithReductionType:weights:")]
[ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)]
public static MLCompute.MLCLossLayer CreateCosineDistanceLoss(MLCompute.MLCReductionType reductionType, MLCompute.MLCTensor? weights);
[<Foundation.Export("cosineDistanceLossWithReductionType:weights:")>]
[<ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)>]
static member CreateCosineDistanceLoss : MLCompute.MLCReductionType * MLCompute.MLCTensor -> MLCompute.MLCLossLayer

Parameters

reductionType
MLCReductionType
weights
MLCTensor

Returns

Attributes

Applies to

CreateCosineDistanceLoss(MLCReductionType, Single)

[Foundation.Export("cosineDistanceLossWithReductionType:weight:")]
[ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)]
public static MLCompute.MLCLossLayer CreateCosineDistanceLoss(MLCompute.MLCReductionType reductionType, float weight);
[<Foundation.Export("cosineDistanceLossWithReductionType:weight:")>]
[<ObjCRuntime.BindingImpl(ObjCRuntime.BindingImplOptions.GeneratedCode | ObjCRuntime.BindingImplOptions.Optimizable)>]
static member CreateCosineDistanceLoss : MLCompute.MLCReductionType * single -> MLCompute.MLCLossLayer

Parameters

reductionType
MLCReductionType
weight
Single

Returns

Attributes

Applies to