Sha256: a8f29eb48036c5cd20f6aa7320bcdcc7128d34c3e09a73e8b81c9b81fc028f65

Contents?: true

Size: 368 Bytes

Versions: 3

Compression:

Stored size: 368 Bytes

Contents

TensorStream::OpMaker.define_operation :rsqrt do |op|
  op.what_it_does "Computes reciprocal of square root of x element-wise."

  op.parameter :input_a, "tensor X", validate: 'FLOATING_POINT_TYPES'
  op.option :name, "Optional name", :nil

  op.define_gradient do |grad, node, params|
    # Returns -0.5 * grad * conj(y)^3.
    i_op(:rsqrt_grad, node, grad)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
tensor_stream-1.0.9 lib/tensor_stream/ops/rsqrt.rb
tensor_stream-1.0.8 lib/tensor_stream/ops/rsqrt.rb
tensor_stream-1.0.7 lib/tensor_stream/ops/rsqrt.rb