att.neuro¶
- att.neuro.get_fallback_params(band='broadband', sfreq=256.0)[source]¶
Return default Takens-embedding parameters for an EEG frequency band.
- Parameters:
- Returns:
Keys:
delay,dimension,bandpass,note.- Return type:
- Raises:
ValueError – If band is not one of the known bands.
- att.neuro.embed_channel(channel_data, band='broadband', sfreq=256.0, condition_threshold=10000.0)[source]¶
Embed a single EEG channel with auto-estimation and fallback.
Strategy: 1. Try TakensEmbedder(“auto”, “auto”) 2. validate_embedding() — check condition number 3. If degenerate or estimation fails: re-embed with fallback_params
- Parameters:
channel_data (1D array of EEG samples)
band (frequency band for fallback params)
sfreq (sampling frequency in Hz)
condition_threshold (condition number threshold for degeneracy)
- Returns:
method: “auto” or “fallback” delay: int dimension: int condition_number: float fallback_reason: str or None
- Return type:
(point_cloud, metadata) where metadata is a dict with
- class att.neuro.EEGLoader(data_path, subject=1)[source]¶
Bases:
objectLoad and preprocess EEG data from common formats.
Supports BDF, EDF, SET (EEGLAB), FIF, and .mat files via MNE-Python.
- Parameters:
- preprocess(bandpass=(1, 45), notch=50.0, reference='average', ica_reject=False)[source]¶
Apply standard preprocessing pipeline.
- Parameters:
bandpass ((low, high) Hz)
notch (line noise frequency (None to skip))
reference (re-referencing scheme ("average" or channel name))
ica_reject (whether to run ICA artifact rejection (slow))
- Return type:
mne.io.Raw
- to_timeseries(picks=None)[source]¶
Extract channel data as numpy array.
- Parameters:
picks (channel names to extract (None = all EEG))
- Return type:
(n_channels, n_samples) array, list of channel names
- get_events()[source]¶
Extract events from annotations or STIM channels.
- Return type:
(n_events, 3) array [sample, 0, event_id] or None if no events found.
- class att.neuro.EEGLoader(data_path, subject=1)[source]¶
Bases:
objectLoad and preprocess EEG data from common formats.
Supports BDF, EDF, SET (EEGLAB), FIF, and .mat files via MNE-Python.
- Parameters:
- preprocess(bandpass=(1, 45), notch=50.0, reference='average', ica_reject=False)[source]¶
Apply standard preprocessing pipeline.
- Parameters:
bandpass ((low, high) Hz)
notch (line noise frequency (None to skip))
reference (re-referencing scheme ("average" or channel name))
ica_reject (whether to run ICA artifact rejection (slow))
- Return type:
mne.io.Raw
- to_timeseries(picks=None)[source]¶
Extract channel data as numpy array.
- Parameters:
picks (channel names to extract (None = all EEG))
- Return type:
(n_channels, n_samples) array, list of channel names
- get_events()[source]¶
Extract events from annotations or STIM channels.
- Return type:
(n_events, 3) array [sample, 0, event_id] or None if no events found.
Auto-with-fallback embedding for EEG channel data.
- att.neuro.embedding.embed_channel(channel_data, band='broadband', sfreq=256.0, condition_threshold=10000.0)[source]¶
Embed a single EEG channel with auto-estimation and fallback.
Strategy: 1. Try TakensEmbedder(“auto”, “auto”) 2. validate_embedding() — check condition number 3. If degenerate or estimation fails: re-embed with fallback_params
- Parameters:
channel_data (1D array of EEG samples)
band (frequency band for fallback params)
sfreq (sampling frequency in Hz)
condition_threshold (condition number threshold for degeneracy)
- Returns:
method: “auto” or “fallback” delay: int dimension: int condition_number: float fallback_reason: str or None
- Return type:
(point_cloud, metadata) where metadata is a dict with
Fallback Takens-embedding parameters for common EEG frequency bands.
- Sources:
Stam, C. J. (2005). Nonlinear dynamical analysis of EEG and MEG. Lehnertz, K. & Elger, C. E. (1998). Can epileptic seizures be predicted?
- att.neuro.eeg_params.get_fallback_params(band='broadband', sfreq=256.0)[source]¶
Return default Takens-embedding parameters for an EEG frequency band.
- Parameters:
- Returns:
Keys:
delay,dimension,bandpass,note.- Return type:
- Raises:
ValueError – If band is not one of the known bands.