python functions to process electroencephalographic recordings