element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Make Life Accessible
  • Challenges & Projects
  • Design Challenges
  • Make Life Accessible
  • More
  • Cancel
Make Life Accessible
Blog EyeLiner - Post 4 - Installing Pygaze
  • Blog
  • Forum
  • Documents
  • Polls
  • Files
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: amgalbu
  • Date Created: 5 May 2016 8:43 AM Date Created
  • Views 388 views
  • Likes 3 likes
  • Comments 2 comments
  • makelifeaccessible
  • python
  • eyeliner
  • opencv
  • make_life_accessible
  • pygaze
Related
Recommended

EyeLiner - Post 4 - Installing Pygaze

amgalbu
amgalbu
5 May 2016

After installing OpenCV, we are now ready to install PyGaze.

First of all, let's install all dependencies (some depencies may have been already installed, but let's stay on the safe side)

In a terminal window , type

 

sudo apt-get install python-numpy python-scipy python-matplotlib python-imaging python-pygame psychopy python-pyglet

 

This will install (in order): NumPy, SciPy, Matplotlib, PIL, PyGame, PsychoPy, and pyglet:

 

Installing PyGaze requires copying the PyGaze directory into Python’s site-packages directory. First check where this directory is located. One way to do this is with Python. To check which is the site-packages directory, type

 

python
>>> import site; site.getsitepackages()
/usr/local/lib/python2.7/dist-packages/
>>> quit()

 

In order to install PyGaze, download the latest version of pygaze from github

 

$ wget https://github.com/esdalmaijer/PyGaze/archive/master.zip

 

Go to the directory where the download was saved (for me, cd ~). To unzip PyGaze, in the terminal type:

 

unzip pygaze.zip

 

To copy the unzipped PyGaze directory into the site-packages directory, type the following in your terminal (of course, you should use the site-packages directory you got from above):

 

sudo cp -r pygaze /usr/local/lib/python2.7/dist-packages/

 

Set the permissions to drwxr-sr-x:

 

sudo chmod 2755 -R /usr/local/lib/python2.7/dist-packages/pygaze/

To test if everything was right, I tried to import the pygaze package from a Python console

 

python
>>> import pygaze

 

As no errors were shown, everything worked perfectly

 

 

There are several example experiments located by default in the directory pygaze/examples/. The PyGaze developers also provide many examples on their website. One that they recommend to start with is the “Simple Tracker Experiment”, which can be downloaded here:http://www.pygaze.org/resources/examples/simple_tracker_experiment.zip.

Unzip, enter the unzipped directory, and let the fun begin by typingpython simple_tracker_experiment.pyin the terminal.

  • Sign in to reply
  • amgalbu
    amgalbu over 9 years ago in reply to DAB

    Hi DAB

    Well currently the eyetracker is non integrated in PyGaze, I am currently working to create a class that wraps the webcam eye tracker and implements the methods of the BaseEyeTracker class. After that, I will for sure publish the results of the analysis

     

    cheers

    Ambrogio

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB over 9 years ago

    Nice post,

     

    Are you going to provide some pictures or video collected using the pygaze?

     

    DAB

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube