Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def read_data(self, mode, dim):
if (np.max(self.file_object.x) - np.min(self.file_object.x)) < 1:
means = np.array([np.mean(self.file_object.X, dtype = np.float64),
np.mean(self.file_object.Y, dtype = np.float64),
np.mean(self.file_object.Z, dtype = np.float64),
0,0,0])
scaled = False
else:
means = np.array([np.mean(self.file_object.x, dtype = np.float64),
np.mean(self.file_object.y, dtype = np.float64),
np.mean(self.file_object.z, dtype = np.float64),
0,0,0])
scaled = True
self.N = len(self.file_object)
self.data_buffer = VBO_Provider(self.file_object, 1000000, means, mode, dim, scaled)