In [1]:
import matplotlib.pyplot as plt
import h5py
import json


NoSpectra = json.load(open("Setting.json"))[0]["Spectra"];
for spectr in ["IRVISUV_0.h5"]:
    
    Spectra = h5py.File(spectr, "r")
    ShotNo=open("ShotNo","r").read()
    
    fig = plt.figure()
    gs = fig.add_gridspec(NoSpectra, hspace=0)
    axs = gs.subplots(sharex=True, sharey=True)
    fig.set_figheight(10);fig.set_figwidth(20)
    plt.suptitle("Golem spectum #" + str(ShotNo) +str(spectr[0:-5]))
    
    for i in range(0, NoSpectra):
        axs[i].plot(Spectra['Wavelengths'][0:], Spectra['Spectra'][i:][0], label=i)
    plt.savefig('ScreenShotAll.png')
In [ ]: