def load_toy_mir():"""Load the toy MIR dataset.""" df_mir = pd.read_csv(toy_mir_url) ws = df_mir.columns.astype(int).to_numpy() X = df_mir.valuesreturn X, ws
X, ws = load_toy_mir()print(f'X shape: {X.shape}, First 5 wavenumbers: {ws[:5]}')
X shape: (50, 1701), First 5 wavenumbers: [600 602 604 606 608]
Scans acquired in the context of a K spiking experiment: In-progress publication.*
Exported source
def load_toy_noisy_mir():""" Load the toy noisy MIR dataset. Scans acquired in the context of a K spiking experiment: In-progress publication. """ df = pd.read_csv(toy_noisy_mir_url) sample_ids = df.sample_id.values wavenumbers = df.columns[1:].to_numpy().astype(float) spectra = df.iloc[:, 1:].to_numpy()return spectra, wavenumbers, sample_ids