Exemple #1
0
 def get_layer(self, in_channels=2, out_channels=3, **kwargs):
     kwargs.setdefault('rpu_config', self.get_rpu_config())
     kwargs.setdefault('bias', self.bias)
     kwargs.setdefault('kernel_size', [2, 2, 2])
     kwargs.setdefault('padding', 2)
     kwargs['rpu_config'].mapping.digital_bias = self.digital_bias
     return AnalogConv3d(in_channels, out_channels, **kwargs)
Exemple #2
0
    def get_layer(self, in_channels=2, out_channels=3, kernel_size=4, padding=2, **kwargs):
        kwargs.setdefault('rpu_config', self.get_rpu_config())
        kwargs.setdefault('bias', self.bias)

        return AnalogConv3d(in_channels, out_channels, kernel_size,
                            padding=padding,
                            **kwargs).cuda()