code: def _get_annotations_gdf(edf_info, sfreq):
      onset, duration, desc = list(), list(), list()
      events = edf_info.get("events", None)
      # Annotations in GDF: events are stored as the following
      # list: `events = [n_events, pos, typ, chn, dur]` where pos is the
      # latency, dur is the duration in samples. They both are
      # numpy.ndarray
      if events is not None and events[1].shape[0] > 0:
          onset = events[1] / sfreq
          duration = events[4] / sfreq
          desc = events[2]
  
      return onset, duration, desc
  
imports: import os
  import re
  from datetime import datetime, timedelta, timezone
  import numpy
  from scipy.interpolate import interp1d
  from ..._fiff.constants import FIFF
  from ..._fiff.meas_info import _empty_info, _unique_channel_names
  from ..._fiff.utils import _blk_read_lims, _mult_cal_one
  from ...annotations import Annotations
  from ...filter import resample
  from ...utils import _validate_type, fill_doc, logger, verbose, warn
  from ..base import BaseRaw, _get_scaling
label_desc: Use image node_id 18 for calling a global function with example usage: _get_annotations_gdf(edf_info, sfreq) and returns: onset,  duration,  desc