{'fraction_non_alphanumeric': 0.028007638446849142, 'fraction_numerical': 0.01464035646085296, 'mean_word_length': 4.932075471698113, 'pattern_counts': {'":': 0, '<': 1, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Video-based sleep detection using ocular signals under the standard conditions of the maintenance of wakefulness test in patients with sleep disorders

Objective. Excessive sleepiness is a physiological reaction to sleep deficiency but can also be caused by underlying medical conditions. Detecting sleep is essential in preventing accidents and for medical diagnostics. Polysomnography (PSG) is considered the gold standard for the detection of sleep. More convenient video-based methods for detecting sleepiness have recently emerged. Approach. The possibility of detecting sleep using video-based ocular signals will be assessed using PSG for reference. Ocular signals and EEG are recorded in parallel under the conditions of the maintenance of wakefulness test (MWT) in 30 patients with sleep disorders. Main results. In detecting sleep, the ocular signal percentage of eyelid closure (PERCLOS) is superior to other ocular signals, resulting in an area under the curve of 0.88. Using a PERCLOS cutoff value of 0.76, sleep is correctly detected with a sensitivity of 89%, a specificity of 76%, the sleep latency is moderately correlated to the reference (rho = 0.66, p < 0.05) and the 95% confidence interval is ±21.1 min. Significance. Ocular signals can facilitate the detection of sleep under the conditions of the MWT but sleep detection should not solely rely on ocular signals. If PSG recordings are not practicable or if a signal is needed that responds relatively early in the wake/sleep transition, the use of PERCLOS for the detection of sleep is reasonable.