MCPcopy Create free account
hub / github.com/modelscope/modelscope / set_device

Method set_device

modelscope/models/nlp/space_T_cn/backbone.py:892–893  ·  view source on GitHub ↗
(self, device)

Source from the content-addressed store, hash-verified

890 self.wlen_model = nn.Linear(iS, max_where_num + 1)
891
892 def set_device(self, device):
893 self.device = device
894
895 def forward(self, wemb_layer, l_n, l_hs, start_index, column_index, tokens,
896 ids):

Callers 13

_init_dist_pytorchFunction · 0.45
_init_dist_mpiFunction · 0.45
_init_dist_slurmFunction · 0.45
device_placementFunction · 0.45
__init__Method · 0.45
__init__Method · 0.45
_trainMethod · 0.45
__init__Method · 0.45
forwardMethod · 0.45
forwardMethod · 0.45
forwardMethod · 0.45
toMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected