Skip to main content

library to read/write EDF+/BDF+ files

Project description

https://codecov.io/gh/holgern/pyedflib/branch/master/graph/badge.svg https://travis-ci.org/holgern/pyedflib.svg?branch=master https://ci.appveyor.com/api/projects/status/49wwigslgtj288q1?svg=true https://readthedocs.org/projects/pyedflib/badge/?version=latest https://api.codacy.com/project/badge/Grade/a80bc8bdb6a342be83b9d03138bfd078 https://anaconda.org/conda-forge/pyedflib/badges/installer/conda.svg https://anaconda.org/conda-forge/pyedflib/badges/version.svg https://anaconda.org/conda-forge/pyedflib/badges/downloads.svg

What is pyEDFlib

pyEDFlib is a python library to read/write EDF+/BDF+ files based on EDFlib.

EDF means European Data Format and was firstly published Kemp1992. In 2003, an improved version of the file protokoll named EDF+ has been published and can be found at Kemp2003.

The EDF/EDF+ format saves all data with 16 Bit. A version which saves all data with 24 Bit, was introduces by the compony BioSemi.

The definition of the EDF/EDF+/BDF/BDF+ format can be found under edfplus.info.

This python toolbox is a fork of the toolbox from Christopher Lee-Messer and uses the EDFlib from Teunis van Beelen. The EDFlib is able to read and write EDF/EDF+/BDF/BDF+ files.

Documentation

Documentation is available online at http://pyedflib.readthedocs.org.

Installation

pyEDFlib can be used with Python 2.7.x or >=3.4. It depends on the Numpy package. To use the newest source code from git, you have to download the source code. You need a C compiler and a recent version of Cython. Go then to the source directory and type:

python setup.py build
python setup.py install

There are binary wheels which can be installed by:

pip install pyEDFlib

Users of the Anaconda Python distribution can directly obtain pre-built Windows, Intel Linux or macOS / OSX binaries from the conda-forge channel. This can be done via:

conda install -c conda-forge pyedflib

The most recent development version can be found on GitHub at https://github.com/holgern/pyedflib.

The latest release, including source and binary packages for Linux, macOS and Windows, is available for download from the Python Package Index. You can find source releases at the Releases Page.

Highlevel interface

pyEDFlib includes an highlevel interface for easy access to read and write edf files. Additionally functionality as anonymizing, dropping or renaming channels can be found there.

from pyedflib import highlevel

# write an edf file
signals = np.random.rand(5, 256*300)*200 # 5 minutes of random signal
channel_names = ['ch1', 'ch2', 'ch3', 'ch4', 'ch5']
signal_headers = highlevel.make_signal_headers(channel_names, sample_rate=256)
header = highlevel.make_header(patientname='patient_x', gender='Female')
highlevel.write_edf('edf_file.edf', signals, signal_headers, header)

# read an edf file
signals, signal_headers, header = highlevel.read_edf('edf_file.edf')
print(signal_headers[0]['sample_rate']) # prints 256

# drop a channel from the file and anonymize
highlevel.drop_channels('edf_file.edf', to_drop=['ch2', 'ch4'])
highlevel.anonymize('edf_file.edf')

License

pyEDFlib is a free Open Source software released under the BSD 2-clause license.

Releases can be cited via Zenodo.

https://zenodo.org/badge/42585968.svg

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyEDFlib-0.1.17.tar.gz (1.1 MB view details)

Uploaded Source

Built Distributions

pyEDFlib-0.1.17-cp38-cp38-win_amd64.whl (583.9 kB view details)

Uploaded CPython 3.8 Windows x86-64

pyEDFlib-0.1.17-cp38-cp38-win32.whl (559.3 kB view details)

Uploaded CPython 3.8 Windows x86

pyEDFlib-0.1.17-cp37-cp37m-win_amd64.whl (581.5 kB view details)

Uploaded CPython 3.7m Windows x86-64

pyEDFlib-0.1.17-cp37-cp37m-win32.whl (557.3 kB view details)

Uploaded CPython 3.7m Windows x86

pyEDFlib-0.1.17-cp36-cp36m-win_amd64.whl (581.4 kB view details)

Uploaded CPython 3.6m Windows x86-64

pyEDFlib-0.1.17-cp36-cp36m-win32.whl (557.2 kB view details)

Uploaded CPython 3.6m Windows x86

pyEDFlib-0.1.17-cp35-cp35m-win_amd64.whl (580.9 kB view details)

Uploaded CPython 3.5m Windows x86-64

pyEDFlib-0.1.17-cp35-cp35m-win32.whl (556.8 kB view details)

Uploaded CPython 3.5m Windows x86

pyEDFlib-0.1.17-cp27-cp27m-win_amd64.whl (584.9 kB view details)

Uploaded CPython 2.7m Windows x86-64

pyEDFlib-0.1.17-cp27-cp27m-win32.whl (562.7 kB view details)

Uploaded CPython 2.7m Windows x86

File details

Details for the file pyEDFlib-0.1.17.tar.gz.

File metadata

  • Download URL: pyEDFlib-0.1.17.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17.tar.gz
Algorithm Hash digest
SHA256 98df227176ab1dc7c16d6ebe0f695235679c55a7be856dc3c1a6a88502d11d06
MD5 f128695696c8499342ae24ae02c117d8
BLAKE2b-256 ab3a63b316df182020c9fe7eab81a91c131a96df53101a3617b57e1a70445a12

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 583.9 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 32350c01d1721fbc7897ec12d8a548324bdfcd0c2bad91c35d5668fd117adaa4
MD5 adfbc88bc5465b56b5df7e8ff7112678
BLAKE2b-256 b92b79e5da6b65c9510b60f54775bad57cb10c516413fd694115cde3d90011d5

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp38-cp38-win32.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp38-cp38-win32.whl
  • Upload date:
  • Size: 559.3 kB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 0876cf517da2806d81f71db90e9f2da9d60017f0a4c8ba5197de065bd506300e
MD5 a6473aacc52a038ade8d8248b866b8cd
BLAKE2b-256 4741ef1029b702df18f357c713f69de54c0d88b607920bcdd7740ab0109b1b95

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 581.5 kB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 be23ddebfe7c0dbce101ab7bb944e8901bca86651d6687c2bb6220c22e54fccd
MD5 bf19636a0ab3f427aae2f2c0c1740b35
BLAKE2b-256 4c783af8be8ebe6b9ecdc23cc65ebfb8b5ab3ecee3b3ce82e7c2b6e764916428

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp37-cp37m-win32.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 557.3 kB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 8f991404e79af7660e8e217fd134c1a7a0b451e7e9b975caf263c32998911f58
MD5 da24ca417c2fa3560dcba44a58e1543a
BLAKE2b-256 9a2c347566a07f0a825c6838c8f723f729fb60450fac4326bc37073edefa5cb7

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 581.4 kB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 2d66dffe1595de7b5f133b0ef249408ba34ab0bc5bd9330b831ce1842c7dd5b6
MD5 557cbd636c89fd8ba5062f2c37ab4c3a
BLAKE2b-256 71bed59e8a3cbcba46decf6dbea917116def476562ae23df60429c6f2cade016

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp36-cp36m-win32.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 557.2 kB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 ee8a5cd142bed97a1a40ad151068a4691deb5dd721832575a3b244396a5f6103
MD5 8838c5ceec2c4c15f25753de7cbb5872
BLAKE2b-256 69a8f09b95e88cd3f73c9a048b560a291ca00dd34131ca9afde1aa455eb834ca

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp35-cp35m-win_amd64.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp35-cp35m-win_amd64.whl
  • Upload date:
  • Size: 580.9 kB
  • Tags: CPython 3.5m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 fcafe555560be983edbfac845e8b08cf5e872b48ae61cc5ac029c442ddb31449
MD5 71b65539413930e41babfec1b29b672f
BLAKE2b-256 53fb9d136b247abc3313df9e59ea1624dcc40a134b2e113c9fd15ad666e83419

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp35-cp35m-win32.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp35-cp35m-win32.whl
  • Upload date:
  • Size: 556.8 kB
  • Tags: CPython 3.5m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp35-cp35m-win32.whl
Algorithm Hash digest
SHA256 b7cff16408f98018400976eddaebb6a4ee5231f263ee476b233b6b78d62318a7
MD5 9749e931b7011360885583e215ddc7c3
BLAKE2b-256 8e1ab569884a32a0759b81ee3104ebe6a7c5414e4d73bd474fd62945e43cfe96

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp27-cp27m-win_amd64.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp27-cp27m-win_amd64.whl
  • Upload date:
  • Size: 584.9 kB
  • Tags: CPython 2.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp27-cp27m-win_amd64.whl
Algorithm Hash digest
SHA256 6075497de6547b512994ee1566da6d41b88adce18811094fbe3d21518b5579fb
MD5 fd64dc3b8baae585d7a4c0ae2d648ee7
BLAKE2b-256 974b2fce246b9b109223b4ad87b9e538f47698a34b3755a5040bb1adf5db51dc

See more details on using hashes here.

File details

Details for the file pyEDFlib-0.1.17-cp27-cp27m-win32.whl.

File metadata

  • Download URL: pyEDFlib-0.1.17-cp27-cp27m-win32.whl
  • Upload date:
  • Size: 562.7 kB
  • Tags: CPython 2.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191101 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.3

File hashes

Hashes for pyEDFlib-0.1.17-cp27-cp27m-win32.whl
Algorithm Hash digest
SHA256 cf67f9c1a74001453b70598ced623dcd815c4b184186ed270970dcf6cbbae69a
MD5 b38db2161c36b41b101a5d7aefb0c250
BLAKE2b-256 a368911c7573c30d7ab61319f85c641c0a4bfcadc8a83114028124938919d04f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page