def shp_apply(self, inputs): X,W,_b = inputs h = ceil_divide(size(X,2) - size(W, 2) + 1, self.sv) w = ceil_divide(size(X,3) - size(W, 3) + 1, self.sh) return [size(X,0), size(W,0), h, w]
def shp_apply(self, inputs): x = inputs[0] assert x.ndim == 4 return [size(x,0), size(x,1), (size(x,2)-self.pad[0]-self.kernel[0]+1)//self.stride[0], (size(x,3)-self.pad[1]-self.kernel[1]+1)//self.stride[0]]