def initialize( self ): # Get config self.velX = float( getParameters(self.config, 'VelocityParameter', 'VelocityXSlideCurve')) self.velY = float( getParameters(self.config, 'VelocityParameter', 'VelocityYSlideCurve')) self.omegaZ = float( getParameters(self.config, 'VelocityParameter', 'OmegaZSlideCurve' )) self.waitingTime = float( getParameters(self.config, "VelocityParameter", "WaitingTimeSlideCurve"))
def initialize(self): # Get time out from config self.scanBallPattern = getParameters(self.config, 'PanTiltPlanner', 'ScanBallPattern') self.scanBallPattern_align2ball = getParameters( self.config, 'PanTiltPlanner', 'ScanBallPatternAlign2Ball') self.scanBallPattern_followball = getParameters( self.config, 'PanTiltPlanner', 'ScanBallPatternFollowBall') self.confidenceThr = float( getParameters(self.config, 'ChangeStateParameter', 'BallConfidenceThreshold'))
def initialize(self): # Get time and velocity x self.velX = float( getParameters(self.config, 'VelocityParameter', 'VelocityXWhenStepToKick')) self.waitTime = float( getParameters(self.config, 'VelocityParameter', 'WaitingTimeAfterStep')) self.tiltAngle = float( getParameters(self.config, 'PanTiltPlanner', 'TiltAngleForLookAtFoot'))
def initialize( self ): # Get omega_z from config self.omegaZ = float( getParameters(self.config, 'VelocityParameter', 'OmegaZWhenRotateToBall')) # Get theta to change state self.smallTheta = float( getParameters(self.config, 'ChangeStateParameter', 'SmallDegreeToAlignTheBall')) # Get tilt limit self.panLimit = float( getParameters(self.config, 'ChangeStateParameter', 'LimitPanAngleDegree')) self.confidenceThr = float( getParameters(self.config, 'ChangeStateParameter', 'BallConfidenceThreshold')) # Get fx and fy from robot config self.fx = float( self.config[ "CameraParameters" ][ "fx" ] )
def initialize(self): ## NOTE : Visittor : Create default for these parameters --> Take it as an args of __init__. # Get velocity of x and y self.velX_max = float( getParameters(self.config, 'VelocityParameter', 'VelocityXWhenFollowTheBall_max')) self.velX_min = float( getParameters(self.config, 'VelocityParameter', 'VelocityXWhenFollowTheBall_min')) self.velX_slope = float( getParameters(self.config, 'VelocityParameter', 'VelocityXWhenFollowTheBall_m')) self.velX_offset = float( getParameters(self.config, 'VelocityParameter', 'VelocityXWhenFollowTheBall_c')) self.omg_max = float( getParameters(self.config, 'VelocityParameter', 'OmegaZWhenRotateToBall_max')) self.omg_min = float( getParameters(self.config, 'VelocityParameter', 'OmegaZWhenRotateToBall_min')) self.omg_slope = float( getParameters(self.config, 'VelocityParameter', 'OmegaZWhenRotateToBall_m')) self.omg_offset = float( getParameters(self.config, 'VelocityParameter', 'OmegaZWhenRotateToBall_c')) self.velY = float( getParameters(self.config, 'VelocityParameter', 'VelocityYWhenFollowTheBall')) # Get theta to change state self.smallTheta = float( getParameters(self.config, 'ChangeStateParameter', 'SmallDegreeToAlignTheBall')) # Get neares distance before kick self.distanceToKick = float( getParameters(self.config, 'ChangeStateParameter', 'NearestDistanceFootballWrtRobot')) self.distanceToPlay = float( getParameters(self.config, 'ChangeStateParameter', 'FarthestDistanceFootballWrtRobot')) # Get limit angle self.limitTiltAngle = float( getParameters(self.config, 'ChangeStateParameter', 'LimitTiltAngleDegree')) self.limitPanAngle = float( getParameters(self.config, 'ChangeStateParameter', 'LimitPanAngleDegree')) self.confidenceThr = float( getParameters(self.config, 'ChangeStateParameter', 'BallConfidenceThreshold')) # Get fx and fy from robot config self.fy = float(self.config["CameraParameters"]["fy"]) self.fx = float(self.config["CameraParameters"]["fx"])