Source code for imhr.eyetracking._eyelink

#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
| `@purpose`: Interface for the SR Research Eyelink eyetracking system.  
| `@date`: Created on Wed Feb 13 15:37:43 2019  
| `@author`: Semeon Risom  
| `@email`: semeon.risom@gmail.com  
| `@url`: https://semeon.io/d/imhr
""" 
# allowed imports
__all__ = ['Eyelink']

# required external libraries
__required__ = ['psychopy','pandas']

# debug
from pdb import set_trace as breakpoint

# local libraries
from .. import settings

if __name__ == "__main__":
	from . import pylink

# check if psychopy is available
try:
	# core
	import time
	import os
	import re
	import psychopy
	import platform
	import pandas as pd
	from pathlib import Path
except ImportError as e:
	pkg = e.name
	x = {'psychopy':'psychopy','pandas':'pandas'}
	pkg = x[pkg] if pkg in x else pkg
	raise Exception("No module named '%s'. Please install from PyPI before continuing."%(pkg),'red')