96733d8496fd607176dc39b31fe81b54286a113b,garage/spaces/discrete.py,Discrete,new_tensor_variable,#Discrete#Any#Any#,56
Before Change
def new_tensor_variable(self, name, extra_dims):
if self.n <= 2**8:
return ext.new_tensor(
name=name, ndim=extra_dims + 1, dtype="uint8")
elif self.n <= 2**16:
return ext.new_tensor(
name=name, ndim=extra_dims + 1, dtype="uint16")
else:
After Change
return hash(self.n)
def new_tensor_variable(self, name, extra_dims):
raise NotImplementedError
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: rlworkgroup/garage
Commit Name: 96733d8496fd607176dc39b31fe81b54286a113b
Time: 2018-07-05
Author: jonashen@users.noreply.github.com
File Name: garage/spaces/discrete.py
Class Name: Discrete
Method Name: new_tensor_variable
Project Name: rlworkgroup/garage
Commit Name: 96733d8496fd607176dc39b31fe81b54286a113b
Time: 2018-07-05
Author: jonashen@users.noreply.github.com
File Name: garage/spaces/box.py
Class Name: Box
Method Name: new_tensor_variable
Project Name: rlworkgroup/garage
Commit Name: 96733d8496fd607176dc39b31fe81b54286a113b
Time: 2018-07-05
Author: jonashen@users.noreply.github.com
File Name: garage/spaces/product.py
Class Name: Product
Method Name: new_tensor_variable