scglue.models.scglue.PairedSCGLUETrainer.compute_losses
- PairedSCGLUETrainer.compute_losses(data, epoch, dsc_only=False)[源代码]
Compute loss functions
- 参数:
data (
typing.Tuple
[typing.Mapping
[str
,torch.Tensor
],typing.Mapping
[str
,torch.Tensor
],typing.Mapping
[str
,torch.Tensor
],typing.Mapping
[str
,torch.Tensor
],typing.Mapping
[str
,torch.Tensor
],typing.Mapping
[str
,torch.Tensor
],torch.Tensor
,torch.Tensor
,torch.Tensor
,torch.Tensor
]) – Data tensorsepoch (
int
) – Current epoch numberdsc_only (
bool
) – Whether to compute the discriminator loss only
- 返回类型:
- 返回:
loss_dict – Dict containing loss values