MCPcopy Create free account
hub / github.com/pytorch/pytorch / get_attributes

Method get_attributes

caffe2/python/core.py:1591–1596  ·  view source on GitHub ↗

Returns the list of attributes in this net for a given `name`. Attributes are user-defined objects added with `add_attribute'.

(self, name)

Source from the content-addressed store, hash-verified

1589 self._attr_dict[name].append(obj)
1590
1591 def get_attributes(self, name):
1592 """
1593 Returns the list of attributes in this net for a given `name`.
1594 Attributes are user-defined objects added with `add_attribute'.
1595 """
1596 return self._attr_dict.get(name, [])
1597
1598 def set_rand_seed(self, seed=100, sequence_seed=True, seed_on_op_def=False):
1599 """

Callers 5

init_fnFunction · 0.80
init_then_scriptMethod · 0.80
get_setup_netsFunction · 0.80
get_all_attributesMethod · 0.80
get_all_attributesMethod · 0.80

Calls 1

getMethod · 0.45

Tested by

no test coverage detected