Example #1
0
 def __init__(self, uid, threat_dist, max_corr_dist, iface_ais) :
     Agent.__init__(self, uid)
     self._iface_ais = iface_ais
     
     # max distance from AIS data point to sensor data point, to consider a sensor data point a threat to AIS point
     self._threat_dist = threat_dist
     
     # max distance from an AIS ship and sensor pt, and be correlated to each other
     self._max_corr_dist = max_corr_dist
     
     self._correlation = {}
     self._all_sonar_data = []
     self._ais_data = {}
     self._radar_data = {}   # keyed by bearing
     self._sonar1_data = {}  # keyed by bearing
     self._sonar2_data = {}  # keyed by bearing
     
     self._event_api = None
     
     self._sensor_history = []
     self._old_correlation = {}
     
     self._sonar_land_data = {}
     self._sonar_land_data_is_ready = False
     
     self._threats = {}
Example #2
0
 def __init__(self, uid, max_agl, f_vel, v_vel) :
     Agent.__init__(self, uid)
     self._forward_vel = f_vel
     self._max_agl = max_agl
     self._vert_vel = v_vel
     self._have_orders = False
     self._new_order = False
Example #3
0
 def __init__(self, owner_node, dest_lat, dest_lon, dest_agl, forward_vel, vert_vel) :
     Agent.__init__(self, owner_node)
     self._dest_lat = dest_lat
     self._dest_lon = dest_lon
     self._dest_agl = dest_agl
     self._forward_vel = forward_vel
     self._vert_vel = vert_vel
Example #4
0
 def __init__(self, uid, threat_dist, ais_threshold, iface_s1, iface_s2, iface_r1, iface_ais, history_num, s_accuracy, threat_step) :
     Agent.__init__(self, uid)
     self._iface_s1 = iface_s1
     self._iface_s2 = iface_s2
     self._iface_r1 = iface_r1
     self._iface_ais = iface_ais
     
     # max distance from AIS data point to sensor data point, to consider a sensor data point a threat to AIS point
     self._threat_dist = threat_dist
     # max distance for an AIS and sensor point to be considered the same point
     # this may not actually get used yet
     self._ais_threshold = ais_threshold
     
     
     self._correlation = {}
     self._sensor_data = []
     self._ais_data = {}
     self._radar_data = {}   # keyed by bearing
     self._sonar1_data = {}  # keyed by bearing
     self._sonar2_data = {}  # keyed by bearing
     
     # Number of sensor data points to keep in history per correlated set
     self._history_num = history_num
     # Max distance the sensor data can be apart to be considered the same sensor point
     self._sensor_accuracy = s_accuracy
     # How quickly to change threat level from new data (weight of old threat level vs new). (0,1]
     self._threat_step = threat_step
     
     self._event_api = None
     
     self._sensor_history = []
Example #5
0
 def __init__(self, uid, forward_vel, iface, pathfile) :
     Agent.__init__(self, uid)
     self._forward_vel = forward_vel
     self._agl = 0.0; 
     self._vert_vel = 0.0; 
     self._pathfile = pathfile
     self._locs = []
     self._iface_name = iface
Example #6
0
 def __init__(self, uid, forward_vel, pathfile):
     Agent.__init__(self, uid)
     self._forward_vel = forward_vel
     self._agl = 0.0
     self._vert_vel = 0.0
     self._pathfile = pathfile
     self._locs = []
     self._follow = None
Example #7
0
 def __init__(self, uid, dataid, forward_vel,pathfile) :
     Agent.__init__(self, uid)
     self._forward_vel = forward_vel
     self._agl = 0.0; 
     self._vert_vel = 0.0; 
     #self._pathfile = "/home/frank/ahoy/src/proto2/ahoy/agents/paths.txt"
     self._pathfile = pathfile
     self._locs = []
     self._dataid = dataid
Example #8
0
 def __init__(self, owner_node, interval, announce_time, rate):
     Agent.__init__(self, owner_node)
     self._interval = interval
     self._announce_time = announce_time
     self._announce_rate = rate
     self._total_time = 0
     self._announced_spill = False
     self._event_api = None
     print "created ChemicalSpillAnnounceAgent"
Example #9
0
 def __init__(self, uid, forward_vel, ip, port, iface_name):
     Agent.__init__(self, uid)
     self._forward_vel = forward_vel
     self._agl = 0.0 
     self._vert_vel = 0
     self._port = port # The port it communicates to the AISDataGen with 
     self._use_ais = True  #if True, uses AISDataGen info to move
     self._iface_name = iface_name  #interface on the node it communicates ais info through
     self._man_paths = []     #list of paths to follow given by human operator
     self._ip = ip 
     self._last_lat = None
     self._NtoS = False
Example #10
0
 def __init__(self, uid, interface_name) :
     Agent.__init__(self, uid)
     self._interface_name = interface_name
Example #11
0
 def __init__(self, uid, sensor_name, interface_name, dest_agent='*') :
     Agent.__init__(self, uid)
     self._sensor_name = sensor_name
     self._interface_name = interface_name
     self._dest_agent = dest_agent
Example #12
0
 def __init__(self, uid, dest, move) :
     Agent.__init__(self, uid)
     self._dest = dest
     self._move = move
Example #13
0
 def __init__(self, uid):
     Agent.__init__(self, uid)
Example #14
0
 def __init__(self, uid, north_west, south_east, vel) :
    Agent.__init__(self, uid)
    self._north_west = north_west
    self._south_east = south_east
    self._vel = vel
    self._new_order = False