(beta, t)
| 2 | |
| 3 | |
| 4 | def compute_alpha(beta, t): |
| 5 | beta = torch.cat([torch.zeros(1).to(beta.device), beta], dim=0) |
| 6 | a = (1 - beta).cumprod(dim=0).index_select(0, t + 1).view(-1, 1, 1, 1) |
| 7 | return a |
| 8 | |
| 9 | |
| 10 | def generalized_steps(x, seq, model, b, **kwargs): |
no outgoing calls
no test coverage detected