* no whispering yet

* whispering

* live whisper

* small support
This commit is contained in:
George Hotz
2023-06-03 18:55:14 -07:00
committed by GitHub
parent ed1963b899
commit b78addf2f8
5 changed files with 258 additions and 4 deletions

View File

@@ -35,6 +35,10 @@ class BatchNorm2d:
return x.batchnorm(self.weight, self.bias, batch_mean, batch_invstd)
# TODO: these Conv lines are terrible
def Conv1d(in_channels, out_channels, kernel_size, stride=1, padding=0, dilation=1, groups=1, bias=True):
return Conv2d(in_channels, out_channels, (kernel_size,), stride, padding, dilation, groups, bias)
class Conv2d:
def __init__(self, in_channels, out_channels, kernel_size, stride=1, padding=0, dilation=1, groups=1, bias=True):
self.kernel_size = (kernel_size, kernel_size) if isinstance(kernel_size, int) else tuple(kernel_size)