lib/torch/nn/parameter.rb in torch-rb-0.9.1 vs lib/torch/nn/parameter.rb in torch-rb-0.9.2

- old
+ new

@@ -1,7 +1,10 @@ module Torch module NN class Parameter < Tensor + # fix for issue w/ assignment methods + alias_method :grad=, :_set_grad + def self.new(data = nil, requires_grad: true) data = Tensor.new unless data _make_subclass(data, requires_grad) end