MCPcopy Index your code
hub / github.com/MoonInTheRiver/DiffSinger / get_model

Method get_model

utils/pl_utils.py:469–472  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

467 return self.use_dp or self.use_ddp
468
469 def get_model(self):
470 is_dp_module = isinstance(self.model, (DDP, DP))
471 model = self.model.module if is_dp_module else self.model
472 return model
473
474 # -----------------------------
475 # MODEL TRAINING

Callers 12

restoreMethod · 0.95
dump_checkpointMethod · 0.95
clip_gradientsMethod · 0.95
print_nan_gradientsMethod · 0.95
evaluateMethod · 0.95
run_evaluationMethod · 0.95
trainMethod · 0.95
run_training_epochMethod · 0.95
run_training_batchMethod · 0.95
optimizer_closureMethod · 0.95
training_forwardMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected