(
mean: float,
std: float,
size: Optional[Iterable[int]],
seed: int,
device: str,
handle: int,
)
| 110 | |
| 111 | |
| 112 | def _normal( |
| 113 | mean: float, |
| 114 | std: float, |
| 115 | size: Optional[Iterable[int]], |
| 116 | seed: int, |
| 117 | device: str, |
| 118 | handle: int, |
| 119 | ) -> Tensor: |
| 120 | if size is None: |
| 121 | size = (1,) |
| 122 | op = GaussianRNG(seed=seed, mean=mean, std=std, handle=handle, dtype="float32") |
| 123 | _ref = Tensor([], dtype="int32", device=device) |
| 124 | shape = utils.astensor1d(size, _ref, dtype="int32", device=device) |
| 125 | (output,) = apply(op, shape) |
| 126 | return output |
| 127 | |
| 128 | |
| 129 | def _gamma( |
no test coverage detected