eps = torch.randn(self.dimX*self.dimY*self.dimZ, 1)
self.A, self.KL_variable = ICA_3D_MM.apply(self.mu.data, self.sigma.data, self.landa.data, eps, self.dimX, self.dimY, self.dimZ)

you should pass Variables to Function. This line should be:
eps = Variable(torch.randn(self.dimX*self.dimY*self.dimZ, 1))
self.A, self.KL_variable = ICA_3D_MM.apply(self.mu, self.sigma, self.landa, eps, self.dimX, self.dimY, self.dimZ)