[NFC] polish applications/Chat/coati/models/utils.py codestyle (#4277)

* [NFC] polish colossalai/context/random/__init__.py code style

* [NFC] polish applications/Chat/coati/models/utils.py code style
pull/4338/head
yuxuan-lou 1 year ago committed by binmakeswell
parent 9e512938f6
commit 0991405361

@ -46,10 +46,7 @@ def log_probs_from_logits(logits: torch.Tensor, labels: torch.Tensor) -> torch.T
return log_probs_labels.squeeze(-1) return log_probs_labels.squeeze(-1)
def calc_action_log_probs(output: torch.Tensor, def calc_action_log_probs(output: torch.Tensor, sequences: torch.LongTensor, num_actions: int) -> torch.Tensor:
sequences: torch.LongTensor,
num_actions: int
) -> torch.Tensor:
"""Calculate action log probs. """Calculate action log probs.
Args: Args:

Loading…
Cancel
Save