class nonlinear(nn.Module):
def __init__(self):
	super(nonlinear, self).__init__()
    self.scale_container = []
    for ii in range(10):
        self.scale_container.append(nn.Parameter(torch.FloatTensor([1.0]).cuda(), requires_grad=True))

def forward(self, x):
	output = None
    for ii in range(10):
        scale = self.scale_container[ii].expand_as(x)
        if output is None:
            output = (F.tanh(scale * x) + 1.0) / 2.0
        else: 
    	output += (F.tanh(scale * x) + 1.0) / 2.0
    return output

class network(nn.Module):
def __init__(self, bitW, bitA):
    super(network, self).__init__()
def forward(self, x):
    x = nonlinear()(x)
    return x

CNN = network()
CNN.cuda()
Then CNN.parameters is None…So Why the parameters are not registered into the model…