Metadata-Version: 2.4
Name: aresneuro
Version: 1.0.0
Summary: Python client for the Ares Neuro CORTEX EEG embedding API
Project-URL: Homepage, https://aresneuro.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: Other/Proprietary License
Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: numpy
Requires-Dist: requests
Requires-Dist: websockets>=11
Provides-Extra: files
Requires-Dist: mne; extra == "files"

# aresneuro

Python client for the Ares Neuro **CORTEX** EEG embedding API. An API key is required (contact Ares Neuro).

```bash
pip install aresneuro
```

```python
import numpy as np
from aresneuro import Cortex

cx = Cortex(api_key="ctx_...")            # or set the CORTEX_API_KEY environment variable

data = np.random.randn(6, 256 * 30)       # your EEG: [n_channels, n_samples], any unit
out = cx.embed(data, sfreq=256, channels=["Fp1", "Fp2", "C3", "C4", "O1", "O2"])
out["embeddings"]                         # (n_windows, 512): one embedding per 10-s window
out["start_s"]                            # window start times (s)

out = cx.embed_file("recording.edf")      # EDF / BDF / FIF / GDF / SET upload

# live streaming: chunks are [n_samples, n_channels]
for msg in cx.stream(chunks, sfreq=256, channels=names, hop_s=2):
    if msg["type"] == "embedding":
        print(msg["end_s"], msg["embedding"][:4])
```

Other helpers: `cx.models()` (model + preprocessing info), `cx.check_montage([...])` (which channel names map to
electrode positions). A different server can be set with `Cortex(base_url=...)` or `CORTEX_API_URL`.
