Example without GUI

This is an example for running SightLab without the GUI. For additional atributes and methods see this page

import vizimport vizfxfrom utils import sightlab
#Code to disable the GUI from showing (set to 1 if you want the GUI)sightlab.is_GUI = 0
#Set environment. Note that environment should be defined before objects of interestenv = vizfx.addChild("utils/resources/environment/dojo.osgb")sightlab.objects.append(env)
#Number of trialssightlab.sceneConfigDict["trials"] = 1
#Add objects of interestbasketball = env.getChild('basketball')soccerball = env.getChild('soccerball')sightlab.gazeObjectsDict = {'basketball':basketball,'soccerball':soccerball}
#Grab objectssightlab.grabObjectsDict = {'basketball':basketball,'soccerball':soccerball}
#run sightlab experimentimport viztaskviztask.schedule(sightlab.experiment)

Note: Make sure to schedule the experiment function after you’ve initialized all the other objects in the scene