Go: Update generated wrapper functions for TensorFlow ops.
PiperOrigin-RevId: 168549989
This commit is contained in:
parent
c8a6131e9f
commit
010922ed91
@ -7321,6 +7321,50 @@ func ResizeNearestNeighbor(scope *Scope, images tf.Output, size tf.Output, optio
|
|||||||
return op.Output(0)
|
return op.Output(0)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ResizeBicubicGradAttr is an optional argument to ResizeBicubicGrad.
|
||||||
|
type ResizeBicubicGradAttr func(optionalAttr)
|
||||||
|
|
||||||
|
// ResizeBicubicGradAlignCorners sets the optional align_corners attribute to value.
|
||||||
|
//
|
||||||
|
// value: If true, rescale grads by (orig_height - 1) / (height - 1), which
|
||||||
|
// exactly aligns the 4 corners of grads and original_image. If false, rescale by
|
||||||
|
// orig_height / height. Treat similarly the width dimension.
|
||||||
|
// If not specified, defaults to false
|
||||||
|
func ResizeBicubicGradAlignCorners(value bool) ResizeBicubicGradAttr {
|
||||||
|
return func(m optionalAttr) {
|
||||||
|
m["align_corners"] = value
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Computes the gradient of bicubic interpolation.
|
||||||
|
//
|
||||||
|
// Arguments:
|
||||||
|
// grads: 4-D with shape `[batch, height, width, channels]`.
|
||||||
|
// original_image: 4-D with shape `[batch, orig_height, orig_width, channels]`,
|
||||||
|
// The image tensor that was resized.
|
||||||
|
//
|
||||||
|
// Returns 4-D with shape `[batch, orig_height, orig_width, channels]`.
|
||||||
|
// Gradients with respect to the input image. Input image must have been
|
||||||
|
// float or double.
|
||||||
|
func ResizeBicubicGrad(scope *Scope, grads tf.Output, original_image tf.Output, optional ...ResizeBicubicGradAttr) (output tf.Output) {
|
||||||
|
if scope.Err() != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
attrs := map[string]interface{}{}
|
||||||
|
for _, a := range optional {
|
||||||
|
a(attrs)
|
||||||
|
}
|
||||||
|
opspec := tf.OpSpec{
|
||||||
|
Type: "ResizeBicubicGrad",
|
||||||
|
Input: []tf.Input{
|
||||||
|
grads, original_image,
|
||||||
|
},
|
||||||
|
Attrs: attrs,
|
||||||
|
}
|
||||||
|
op := scope.AddOperation(opspec)
|
||||||
|
return op.Output(0)
|
||||||
|
}
|
||||||
|
|
||||||
// SummaryWriterAttr is an optional argument to SummaryWriter.
|
// SummaryWriterAttr is an optional argument to SummaryWriter.
|
||||||
type SummaryWriterAttr func(optionalAttr)
|
type SummaryWriterAttr func(optionalAttr)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user