-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Moved sample signals - Added sample signal loading module
- Loading branch information
Showing
11 changed files
with
80 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
from . import heartrate | ||
from . import electromiography | ||
from . import electrodermalactivity | ||
from . import sampledata | ||
|
||
__version__ = '0.0.7' #Version Control | ||
|
||
__version__ = '0.0.6' #Version Control |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# -*- coding: utf-8 -*- | ||
""" This module is used to load sample data from the share/data folder. """ | ||
import os | ||
import pickle | ||
import pkg_resources | ||
############################################################################### | ||
# # | ||
# DEBUG # | ||
# # | ||
############################################################################### | ||
|
||
def loadsampleECG(): | ||
fakesignal = os.stat(pkg_resources.resource_filename('pysiology','../share/data/convertedECG.pkl')) | ||
with open(fakesignal,"rb") as f: # Python 3: open(..., 'rb') | ||
return(pickle.load(f)) #load a fake signal | ||
|
||
def loadsampleEMG(): | ||
fakesignal = os.stat(pkg_resources.resource_filename('pysiology','../share/data/convertedEMG.pkl')) | ||
with open(fakesignal,"rb") as f: # Python 3: open(..., 'rb') | ||
return(pickle.load(f)) #load a fake signal | ||
|
||
def loadsampleEDA(): | ||
fakesignal = os.stat(pkg_resources.resource_filename('pysiology','../share/data/convertedEDA.pkl')) | ||
with open(fakesignal,"rb") as f: # Python 3: open(..., 'rb') | ||
return(pickle.load(f)) #load a fake signal | ||
|
||
""" For debug purposes""" | ||
|
||
if(__name__=='__main__'): | ||
ecg = loadsampleECG() | ||
emg = loadsampleEMG() | ||
eda = loadsampleEDA() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,19 @@ | ||
from setuptools import setup | ||
import os | ||
|
||
datadir = os.path.join("share","data") | ||
datafiles = [(d,[os.path.join(d,f) for f in files]) for d, folders, files in os.walk(datadir)] | ||
|
||
|
||
setup(name='pysiology', | ||
version='0.0.6', | ||
version='0.0.7', | ||
description='Physiological signal processing in Python', | ||
long_description="A simple python package for physiological signal processing (ECG,EMG,GSR).", | ||
long_description="A simple python package for physiological signal processing (ECG,EMG,GSR). Tutorial and documentation can be found on the Github Repository or at pysiology.rtfd.io.", | ||
url='https://github.com/Gabrock94/Pysiology', | ||
download_url='https://github.com/Gabrock94/Pysiology/archive/0.0.6.tar.gz', | ||
author='Giulio Gabrieli', | ||
author_email='[email protected]', | ||
license='Apache2', | ||
license='GPL-3.0', | ||
packages=['pysiology'], | ||
install_requires=[ | ||
'numpy', | ||
|
@@ -22,10 +27,10 @@ | |
# 3 - Alpha | ||
# 4 - Beta | ||
# 5 - Production/Stable | ||
'Development Status :: 3 - Alpha', | ||
'Development Status :: 4 - Beta', | ||
|
||
# Pick your license as you wish (should match "license" above) | ||
'License :: OSI Approved :: MIT License', | ||
'License :: OSI Approved :: GNU General Public License (GPL)', | ||
|
||
# Specify the Python versions you support here. In particular, ensure | ||
# that you indicate whether you support Python 2, Python 3 or both. | ||
|
@@ -37,4 +42,6 @@ | |
'Programming Language :: Python :: 3.3', | ||
'Programming Language :: Python :: 3.4', | ||
], | ||
zip_safe=False) | ||
zip_safe=False, | ||
include_package_data=True, | ||
data_files = datafiles) |
File renamed without changes.
File renamed without changes.
File renamed without changes.