how to make events

i have a 30min EEG edf file, but has no annotation(i dont know why), but i do have several timestamp file. so i want to make the events base on the timestamp file(like events1-10s, events2-30s, events3-35s…), how can i do this?

i only know the “make_fixed_length_events”, but my events is random, not fixed

To understand correctly, you have an EEG recording and events in a separate file?
How are the events synchronized with the EEG recording?

Mathieu

the eeg recording has the start time stamp(like 2023-04-19 10:10:30), and the events are recorded by psychopy. two time stamp is synchronized

i assume that two timestamp is synchronized :joy:

from now on, i use the “raw.crop” to cut the signals into many sets, that is so inconvenient

If the time is indeed synchronized across the two files, you can create an event array based on your text file. This is literally a 2D NumPy array (see e.g. here). Parsing your text file is probably the main difficulty here, as this will need to be customized to your text file.