I am just wondering how to solve the attribute error in
The error is
‘list’ object has no attribute ‘astype’.
My related code is as blow.
def _init_mean_std(self, data): data = data.astype('float32') self.mean, self.std = np.mean(data), np.std(data) self.save_meanstd() return data
Is there anyone who can advice to me?