There seems to be a bug in how sleeps states are found:
https://github.com/wadpac/SleepStageClassification/blob/5b288995e62bbd66faa66bd932b06af8a65f8445/preprocessing/preproc_psgnewcastle.py#L71
Below is a plot, on the top raw the sleep states derived from get_sleep_states and on the bottom the psg file sleep states. See the red circles, in the get_sleep_states are labeled as NaN, whereas in the original psg they are labeled:

In the middle of a psg recording period there should not be any NaNs as the psg data is always labeled.
There seems to be a bug in how sleeps states are found:
https://github.com/wadpac/SleepStageClassification/blob/5b288995e62bbd66faa66bd932b06af8a65f8445/preprocessing/preproc_psgnewcastle.py#L71
Below is a plot, on the top raw the sleep states derived from get_sleep_states and on the bottom the psg file sleep states. See the red circles, in the get_sleep_states are labeled as NaN, whereas in the original psg they are labeled:

In the middle of a psg recording period there should not be any NaNs as the psg data is always labeled.