\doxysection{pygaze.\+\_\+eyetracker.\+libsmi Namespace Reference}
\hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi}{}\label{namespacepygaze_1_1__eyetracker_1_1libsmi}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection*{Classes}
\begin{DoxyCompactItemize}
\item 
class \mbox{\hyperlink{classpygaze_1_1__eyetracker_1_1libsmi_1_1_s_m_itracker}{SMItracker}}
\end{DoxyCompactItemize}
\doxysubsubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a5a1fa062c59f3085256168d848d6dd85}{errorstring}} (returncode)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a35ded0eac309dddb5150d5bdc5a1bad1}{deg2pix}} (cmdist, angle, pixpercm)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a46ebd17ffdd53e5b4b20bd919bef3f34}{pupil\+\_\+size}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a30c69d258cc69a8fe4fd35f9bd678ec6}{sample}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a54222b2d794a02999e60721e91f91b9e}{send\+\_\+command}} (self, cmd)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_af14b8205a34383a7159f352b13286f05}{send\+\_\+message}} (self, msg)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a72be42a58f4af269cb1ea6b79a667bad}{set\+\_\+backdrop}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a32f3410b3a1ddb7bf209a4f681c2dff9}{set\+\_\+eye\+\_\+used}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a0dbcd9803be68f576c99766d4a2dc980}{start\+\_\+recording}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a2f0076289277de202f36f60e8371cbc1}{status\+\_\+msg}} (self, msg)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a2aa719fd1cb4952ac239a4ac4cd10e55}{stop\+\_\+recording}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a213510018aa8ea8ca766a469762d27f4}{set\+\_\+detection\+\_\+type}} (self, \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_aaaaaaa7185fa9100e609a912405ced77}{eventdetection}})
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a1b8ccabba4e6efb792531246069add4f}{wait\+\_\+for\+\_\+event}} (self, event)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_aa1c5fe6f961104c1af7810a3f4264e66}{wait\+\_\+for\+\_\+blink\+\_\+end}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a9bb578415de62ccf1358bf955c16e470}{wait\+\_\+for\+\_\+blink\+\_\+start}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a531427f62b4460f284d886e4d4f6e53f}{wait\+\_\+for\+\_\+fixation\+\_\+end}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a2d5d7268dad8a6890d46b29210e6c097}{wait\+\_\+for\+\_\+fixation\+\_\+start}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a6d9c8ca66c4a1bf86dd5793ec39d4424}{wait\+\_\+for\+\_\+saccade\+\_\+end}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a66f87dba164c75099c304ed39e2d56f9}{wait\+\_\+for\+\_\+saccade\+\_\+start}} (self)
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_ab0a663f7bb0c398616d67b807aa8458e}{is\+\_\+valid\+\_\+sample}} (self, gazepos)
\end{DoxyCompactItemize}
\doxysubsubsection*{Variables}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a152828d4a68162d3801173f8f003de01}{res}} = i\+View\+XAPI.\+i\+V\+\_\+\+Set\+Logger(c\+\_\+int(1), c\+\_\+char\+\_\+p(logfile + \textquotesingle{}\+\_\+\+SMILOG.\+txt\textquotesingle{}))
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_afc2131a9cb77cdf889a88e1f45fed17c}{err}} = \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a5a1fa062c59f3085256168d848d6dd85}{errorstring}}(\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a152828d4a68162d3801173f8f003de01}{res}})
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a81e6e38b0d61c03609cae4e2242d52ce}{samplerate}}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_ab29f3a22e73adf829b62c35907378da5}{sampletime}}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a9d2c41fbf86de8d44582c090765b7f5a}{connected}}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a967af4481e51b984ab46d8561e949a71}{eye\+\_\+used}} = self.\+left\+\_\+eye\+:
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a2c6f4dc608ebf1c59f99af0b41ccadd2}{prevps}} = ps
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a4b1e490f61e26358aa750bf9811595fe}{prevsample}} = newsample\mbox{[}\+:\mbox{]}
\item 
bool \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a64bd57607e10e1c45e09d2265a475694}{recording}} = True
\item 
\mbox{\hyperlink{namespacepygaze_1_1py3compat_a00268eef6a7a5c7241ae0072047d8171}{str}} \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_aaaaaaa7185fa9100e609a912405ced77}{eventdetection}} = eventdetection
\item 
\# weigthed distance(sx/tx) \texorpdfstring{$\ast$}{*}\texorpdfstring{$\ast$}{*}2+(sy/ty) \texorpdfstring{$\ast$}{*}\texorpdfstring{$\ast$}{*}2 $>$ 1 means movement larger than RMS noise \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a5ca27defbdd9ba31c3d09b484178dad8}{weightdist}} = newpos\mbox{[}1\mbox{]}-\/prevpos\mbox{[}1\mbox{]}
\item 
\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a6cf632c19cfd83d5902a2ea165c29311}{pxacctresh}} = (v1-\/v0) / (t1-\/t0)
\end{DoxyCompactItemize}


\doxysubsection{Function Documentation}
\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a35ded0eac309dddb5150d5bdc5a1bad1}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!deg2pix@{deg2pix}}
\index{deg2pix@{deg2pix}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{deg2pix()}{deg2pix()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a35ded0eac309dddb5150d5bdc5a1bad1} 
pygaze.\+\_\+eyetracker.\+libsmi.\+deg2pix (\begin{DoxyParamCaption}\item[{}]{cmdist}{, }\item[{}]{angle}{, }\item[{}]{pixpercm}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Convierte un ángulo visual en tamaño en píxeles.

Argumentos:
    cmdist -- Distancia al monitor en centímetros.
    angle -- Tamaño del estímulo en ángulo visual.
    pixpercm -- Cantidad de píxeles por centímetro en la pantalla.

Retorna:
    pixelsize -- Tamaño del estímulo en píxeles.
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a5a1fa062c59f3085256168d848d6dd85}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!errorstring@{errorstring}}
\index{errorstring@{errorstring}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{errorstring()}{errorstring()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a5a1fa062c59f3085256168d848d6dd85} 
pygaze.\+\_\+eyetracker.\+libsmi.\+errorstring (\begin{DoxyParamCaption}\item[{}]{returncode}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Devuelve una cadena con la descripción del error asociado al código de retorno dado.

Argumentos:
    returncode -- Código de error de iViewXAPI (un número entero).

Retorna:
    errorstring -- Cadena que describe el error asociado al código especificado.
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_ab0a663f7bb0c398616d67b807aa8458e}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!is\_valid\_sample@{is\_valid\_sample}}
\index{is\_valid\_sample@{is\_valid\_sample}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{is\_valid\_sample()}{is\_valid\_sample()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_ab0a663f7bb0c398616d67b807aa8458e} 
pygaze.\+\_\+eyetracker.\+libsmi.\+is\+\_\+valid\+\_\+sample (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{gazepos}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Checks if the sample provided is valid, based on SMI specific
        criteria (for internal use)

        arguments
        gazepos     --  a (x,y) gaze position tuple, as returned by
                        self.sample()

        returns
        valid           --  a Boolean: True on a valid sample, False on
                        an invalid sample
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a46ebd17ffdd53e5b4b20bd919bef3f34}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!pupil\_size@{pupil\_size}}
\index{pupil\_size@{pupil\_size}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{pupil\_size()}{pupil\_size()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a46ebd17ffdd53e5b4b20bd919bef3f34} 
pygaze.\+\_\+eyetracker.\+libsmi.\+pupil\+\_\+size (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Return pupil size

        arguments
        None

        returns
        pupil size  -- returns pupil diameter for the eye that is currently
                   being tracked (as specified by self.eye_used) or -1
                   when no data is obtainable
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a30c69d258cc69a8fe4fd35f9bd678ec6}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!sample@{sample}}
\index{sample@{sample}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{sample()}{sample()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a30c69d258cc69a8fe4fd35f9bd678ec6} 
pygaze.\+\_\+eyetracker.\+libsmi.\+sample (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Returns newest available gaze position

        arguments
        None

        returns
        sample  -- an (x,y) tuple or a (-1,-1) on an error
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a54222b2d794a02999e60721e91f91b9e}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!send\_command@{send\_command}}
\index{send\_command@{send\_command}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{send\_command()}{send\_command()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a54222b2d794a02999e60721e91f91b9e} 
pygaze.\+\_\+eyetracker.\+libsmi.\+send\+\_\+command (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{cmd}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Sends a command to the eye tracker

        arguments
        cmd     -- the command (a string value) to be sent to iViewX

        returns
        Nothing
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_af14b8205a34383a7159f352b13286f05}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!send\_message@{send\_message}}
\index{send\_message@{send\_message}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{send\_message()}{send\_message()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_af14b8205a34383a7159f352b13286f05} 
pygaze.\+\_\+eyetracker.\+libsmi.\+send\+\_\+message (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{msg}{}\end{DoxyParamCaption})}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a72be42a58f4af269cb1ea6b79a667bad}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!set\_backdrop@{set\_backdrop}}
\index{set\_backdrop@{set\_backdrop}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{set\_backdrop()}{set\_backdrop()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a72be42a58f4af269cb1ea6b79a667bad} 
pygaze.\+\_\+eyetracker.\+libsmi.\+set\+\_\+backdrop (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Not supported for SMItracker (yet)\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a213510018aa8ea8ca766a469762d27f4}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!set\_detection\_type@{set\_detection\_type}}
\index{set\_detection\_type@{set\_detection\_type}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{set\_detection\_type()}{set\_detection\_type()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a213510018aa8ea8ca766a469762d27f4} 
pygaze.\+\_\+eyetracker.\+libsmi.\+set\+\_\+detection\+\_\+type (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{eventdetection}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Set the event detection type to either PyGaze algorithms, or
        native algorithms as provided by the manufacturer (only if
        available: detection type will default to PyGaze if no native
        functions are available)

        arguments
        eventdetection  --  a string indicating which detection type
                        should be employed: either 'pygaze' for
                        PyGaze event detection algorithms or
                        'native' for manufacturers algorithms (only
                        if available; will default to 'pygaze' if no
                        native event detection is available)
        returns     --  detection type for saccades, fixations and
                        blinks in a tuple, e.g.
                        ('pygaze','native','native') when 'native'
                        was passed, but native detection was not
                        available for saccade detection
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a32f3410b3a1ddb7bf209a4f681c2dff9}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!set\_eye\_used@{set\_eye\_used}}
\index{set\_eye\_used@{set\_eye\_used}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{set\_eye\_used()}{set\_eye\_used()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a32f3410b3a1ddb7bf209a4f681c2dff9} 
pygaze.\+\_\+eyetracker.\+libsmi.\+set\+\_\+eye\+\_\+used (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Logs the eye_used variable, based on which eye was specified
        (if both eyes are being tracked, the left eye is used)

        arguments
        None

        returns
        Nothing -- logs which eye is used by calling self.log_var, e.g.
                   self.log_var("eye_used", "right")
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a0dbcd9803be68f576c99766d4a2dc980}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!start\_recording@{start\_recording}}
\index{start\_recording@{start\_recording}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{start\_recording()}{start\_recording()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a0dbcd9803be68f576c99766d4a2dc980} 
pygaze.\+\_\+eyetracker.\+libsmi.\+start\+\_\+recording (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Starts recording eye position

        arguments
        None

        returns
        Nothing -- sets self.recording to True when recording is
                   successfully started
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a2f0076289277de202f36f60e8371cbc1}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!status\_msg@{status\_msg}}
\index{status\_msg@{status\_msg}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{status\_msg()}{status\_msg()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a2f0076289277de202f36f60e8371cbc1} 
pygaze.\+\_\+eyetracker.\+libsmi.\+status\+\_\+msg (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{msg}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Not supported for SMItracker (yet)\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a2aa719fd1cb4952ac239a4ac4cd10e55}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!stop\_recording@{stop\_recording}}
\index{stop\_recording@{stop\_recording}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{stop\_recording()}{stop\_recording()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a2aa719fd1cb4952ac239a4ac4cd10e55} 
pygaze.\+\_\+eyetracker.\+libsmi.\+stop\+\_\+recording (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Stop recording eye position

        arguments
        None

        returns
        Nothing -- sets self.recording to False when recording is
                   successfully started
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_aa1c5fe6f961104c1af7810a3f4264e66}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_blink\_end@{wait\_for\_blink\_end}}
\index{wait\_for\_blink\_end@{wait\_for\_blink\_end}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_blink\_end()}{wait\_for\_blink\_end()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_aa1c5fe6f961104c1af7810a3f4264e66} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+blink\+\_\+end (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Waits for a blink end and returns the blink ending time

        arguments
        None

        returns
        timestamp       --  blink ending time in milliseconds, as
                        measured from experiment begin time
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a9bb578415de62ccf1358bf955c16e470}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_blink\_start@{wait\_for\_blink\_start}}
\index{wait\_for\_blink\_start@{wait\_for\_blink\_start}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_blink\_start()}{wait\_for\_blink\_start()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a9bb578415de62ccf1358bf955c16e470} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+blink\+\_\+start (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Waits for a blink start and returns the blink starting time

        arguments
        None

        returns
        timestamp       --  blink starting time in milliseconds, as
                        measured from experiment begin time
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a1b8ccabba4e6efb792531246069add4f}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_event@{wait\_for\_event}}
\index{wait\_for\_event@{wait\_for\_event}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_event()}{wait\_for\_event()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a1b8ccabba4e6efb792531246069add4f} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+event (\begin{DoxyParamCaption}\item[{}]{self}{, }\item[{}]{event}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Waits for event

        arguments
        event       -- an integer event code, one of the following:
                    3 = STARTBLINK
                    4 = ENDBLINK
                    5 = STARTSACC
                    6 = ENDSACC
                    7 = STARTFIX
                    8 = ENDFIX

        returns
        outcome -- a self.wait_for_* method is called, depending on the
                   specified event; the return values of corresponding
                   method are returned
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a531427f62b4460f284d886e4d4f6e53f}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_fixation\_end@{wait\_for\_fixation\_end}}
\index{wait\_for\_fixation\_end@{wait\_for\_fixation\_end}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_fixation\_end()}{wait\_for\_fixation\_end()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a531427f62b4460f284d886e4d4f6e53f} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+fixation\+\_\+end (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Returns time and gaze position when a fixation has ended;
        function assumes that a 'fixation' has ended when a deviation of
        more than self.pxfixtresh from the initial fixation position has
        been detected (self.pxfixtresh is created in self.calibration,
        based on self.fixtresh, a property defined in self.__init__)

        arguments
        None

        returns
        time, gazepos   -- time is the starting time in milliseconds (from
                       expstart), gazepos is a (x,y) gaze position
                       tuple of the position from which the fixation
                       was initiated
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a2d5d7268dad8a6890d46b29210e6c097}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_fixation\_start@{wait\_for\_fixation\_start}}
\index{wait\_for\_fixation\_start@{wait\_for\_fixation\_start}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_fixation\_start()}{wait\_for\_fixation\_start()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a2d5d7268dad8a6890d46b29210e6c097} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+fixation\+\_\+start (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Returns starting time and position when a fixation is started;
        function assumes a 'fixation' has started when gaze position
        remains reasonably stable (i.e. when most deviant samples are
        within self.pxfixtresh) for five samples in a row (self.pxfixtresh
        is created in self.calibration, based on self.fixtresh, a property
        defined in self.__init__)

        arguments
        None

        returns
        time, gazepos   -- time is the starting time in milliseconds (from
                       expstart), gazepos is a (x,y) gaze position
                       tuple of the position from which the fixation
                       was initiated
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a6d9c8ca66c4a1bf86dd5793ec39d4424}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_saccade\_end@{wait\_for\_saccade\_end}}
\index{wait\_for\_saccade\_end@{wait\_for\_saccade\_end}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_saccade\_end()}{wait\_for\_saccade\_end()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a6d9c8ca66c4a1bf86dd5793ec39d4424} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+saccade\+\_\+end (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Returns ending time, starting and end position when a saccade is
        ended; based on Dalmaijer et al. (2013) online saccade detection
        algorithm

        arguments
        None

        returns
        endtime, startpos, endpos   -- endtime in milliseconds (from
                               expbegintime); startpos and endpos
                               are (x,y) gaze position tuples
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a66f87dba164c75099c304ed39e2d56f9}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!wait\_for\_saccade\_start@{wait\_for\_saccade\_start}}
\index{wait\_for\_saccade\_start@{wait\_for\_saccade\_start}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{wait\_for\_saccade\_start()}{wait\_for\_saccade\_start()}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a66f87dba164c75099c304ed39e2d56f9} 
pygaze.\+\_\+eyetracker.\+libsmi.\+wait\+\_\+for\+\_\+saccade\+\_\+start (\begin{DoxyParamCaption}\item[{}]{self}{}\end{DoxyParamCaption})}

\begin{DoxyVerb}Returns starting time and starting position when a saccade is
        started; based on Dalmaijer et al. (2013) online saccade detection
        algorithm

        arguments
        None

        returns
        endtime, startpos   -- endtime in milliseconds (from expbegintime);
                       startpos is an (x,y) gaze position tuple
\end{DoxyVerb}
 

\doxysubsection{Variable Documentation}
\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a9d2c41fbf86de8d44582c090765b7f5a}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!connected@{connected}}
\index{connected@{connected}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{connected}{connected}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a9d2c41fbf86de8d44582c090765b7f5a} 
pygaze.\+\_\+eyetracker.\+libsmi.\+connected}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_afc2131a9cb77cdf889a88e1f45fed17c}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!err@{err}}
\index{err@{err}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{err}{err}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_afc2131a9cb77cdf889a88e1f45fed17c} 
pygaze.\+\_\+eyetracker.\+libsmi.\+err = \mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a5a1fa062c59f3085256168d848d6dd85}{errorstring}}(\mbox{\hyperlink{namespacepygaze_1_1__eyetracker_1_1libsmi_a152828d4a68162d3801173f8f003de01}{res}})}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_aaaaaaa7185fa9100e609a912405ced77}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!eventdetection@{eventdetection}}
\index{eventdetection@{eventdetection}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{eventdetection}{eventdetection}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_aaaaaaa7185fa9100e609a912405ced77} 
\mbox{\hyperlink{namespacepygaze_1_1py3compat_a00268eef6a7a5c7241ae0072047d8171}{str}} pygaze.\+\_\+eyetracker.\+libsmi.\+eventdetection = eventdetection}

\begin{DoxyVerb}Set the event detection type to either PyGaze algorithms, or
        native algorithms as provided by the manufacturer (only if
        available: detection type will default to PyGaze if no native
        functions are available)

        arguments
        eventdetection  --  a string indicating which detection type
                        should be employed: either 'pygaze' for
                        PyGaze event detection algorithms or
                        'native' for manufacturers algorithms (only
                        if available; will default to 'pygaze' if no
                        native event detection is available)
        returns     --  detection type for saccades, fixations and
                        blinks in a tuple, e.g.
                        ('pygaze','native','native') when 'native'
                        was passed, but native detection was not
                        available for saccade detection
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a967af4481e51b984ab46d8561e949a71}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!eye\_used@{eye\_used}}
\index{eye\_used@{eye\_used}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{eye\_used}{eye\_used}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a967af4481e51b984ab46d8561e949a71} 
pygaze.\+\_\+eyetracker.\+libsmi.\+eye\+\_\+used = self.\+left\+\_\+eye\+:}

\begin{DoxyVerb}Logs the eye_used variable, based on which eye was specified
        (if both eyes are being tracked, the left eye is used)

        arguments
        None

        returns
        Nothing -- logs which eye is used by calling self.log_var, e.g.
                   self.log_var("eye_used", "right")
\end{DoxyVerb}
 \Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a2c6f4dc608ebf1c59f99af0b41ccadd2}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!prevps@{prevps}}
\index{prevps@{prevps}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{prevps}{prevps}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a2c6f4dc608ebf1c59f99af0b41ccadd2} 
pygaze.\+\_\+eyetracker.\+libsmi.\+prevps = ps}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a4b1e490f61e26358aa750bf9811595fe}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!prevsample@{prevsample}}
\index{prevsample@{prevsample}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{prevsample}{prevsample}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a4b1e490f61e26358aa750bf9811595fe} 
pygaze.\+\_\+eyetracker.\+libsmi.\+prevsample = newsample\mbox{[}\+:\mbox{]}}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a6cf632c19cfd83d5902a2ea165c29311}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!pxacctresh@{pxacctresh}}
\index{pxacctresh@{pxacctresh}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{pxacctresh}{pxacctresh}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a6cf632c19cfd83d5902a2ea165c29311} 
pygaze.\+\_\+eyetracker.\+libsmi.\+pxacctresh = (v1-\/v0) / (t1-\/t0)}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a64bd57607e10e1c45e09d2265a475694}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!recording@{recording}}
\index{recording@{recording}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{recording}{recording}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a64bd57607e10e1c45e09d2265a475694} 
bool pygaze.\+\_\+eyetracker.\+libsmi.\+recording = True}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a152828d4a68162d3801173f8f003de01}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!res@{res}}
\index{res@{res}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{res}{res}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a152828d4a68162d3801173f8f003de01} 
pygaze.\+\_\+eyetracker.\+libsmi.\+res = i\+View\+XAPI.\+i\+V\+\_\+\+Set\+Logger(c\+\_\+int(1), c\+\_\+char\+\_\+p(logfile + \textquotesingle{}\+\_\+\+SMILOG.\+txt\textquotesingle{}))}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a81e6e38b0d61c03609cae4e2242d52ce}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!samplerate@{samplerate}}
\index{samplerate@{samplerate}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{samplerate}{samplerate}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a81e6e38b0d61c03609cae4e2242d52ce} 
pygaze.\+\_\+eyetracker.\+libsmi.\+samplerate}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_ab29f3a22e73adf829b62c35907378da5}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!sampletime@{sampletime}}
\index{sampletime@{sampletime}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{sampletime}{sampletime}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_ab29f3a22e73adf829b62c35907378da5} 
pygaze.\+\_\+eyetracker.\+libsmi.\+sampletime}

\Hypertarget{namespacepygaze_1_1__eyetracker_1_1libsmi_a5ca27defbdd9ba31c3d09b484178dad8}\index{pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}!weightdist@{weightdist}}
\index{weightdist@{weightdist}!pygaze.\_eyetracker.libsmi@{pygaze.\_eyetracker.libsmi}}
\doxysubsubsection{\texorpdfstring{weightdist}{weightdist}}
{\footnotesize\ttfamily \label{namespacepygaze_1_1__eyetracker_1_1libsmi_a5ca27defbdd9ba31c3d09b484178dad8} 
\# weigthed distance (sx/tx)\texorpdfstring{$\ast$}{*}\texorpdfstring{$\ast$}{*}2 + (sy/ty)\texorpdfstring{$\ast$}{*}\texorpdfstring{$\ast$}{*}2 $>$ 1 means movement larger than RMS noise pygaze.\+\_\+eyetracker.\+libsmi.\+weightdist = newpos\mbox{[}1\mbox{]}-\/prevpos\mbox{[}1\mbox{]}}

