def __init__(self, df_source_info, df_fluxes, df_wavelengths, load_model, weights_path=''):
    self.load_model = load_model
    self.weights_path = weights_path
    X = self._prepare_data(df_source_info, df_fluxes, df_wavelengths)
    indeces = list(range(len(X)))
    (X_train, X_test, self.i_train, self.i_test) = train_test_split(X, 0.2, indeces=indeces)
    (X_train, X_val, self.i_train, self.i_val) = train_test_split(X_train, 0.2, indeces=indeces)
    self.scaler = StandardScaler()
    X_train = self.scaler.fit_transform(X_train)
    X_test = self.scaler.transform(X_test)
    X_val = self.scaler.transform(X_val)
    self.X_train = np.expand_dims(X_train, axis=2)
    self.X_test = np.expand_dims(X_test, axis=2)
    self.X_val = np.expand_dims(X_val, axis=2)
def __init__(self, df_source_info, df_fluxes, df_wavelengths, load_model, weights_path=):
    self.load_model = load_model
    self.weights_path = weights_path
    X = self._prepare_data(df_source_info, df_fluxes, df_wavelengths)
    indeces = list(range(len(X)))
    (X_train, X_test, self.i_train, self.i_test) = train_test_split(X, 0.2, indeces=indeces)
    (X_train, X_val, self.i_train, self.i_val) = train_test_split(X_train, 0.2, indeces=indeces)
    self.scaler = StandardScaler()
    X_train = self.scaler.fit_transform(X_train)
    X_test = self.scaler.transform(X_test)
    X_val = self.scaler.transform(X_val)
    self.X_train = np.expand_dims(X_train, axis=2)
    self.X_test = np.expand_dims(X_test, axis=2)
    self.X_val = np.expand_dims(X_val, axis=2)