diff --git a/PAR 152/Yolo V3/TensorFlow-2.x-YOLOv3-master/MCL.py b/PAR 152/Yolo V3/TensorFlow-2.x-YOLOv3-master/MCL.py index cb8cf57cd4d3f4b04d576b50fc22ceb7ea3a3e0d..4cd5bdff5968efbe0278dc948566f51359df8384 100644 --- a/PAR 152/Yolo V3/TensorFlow-2.x-YOLOv3-master/MCL.py +++ b/PAR 152/Yolo V3/TensorFlow-2.x-YOLOv3-master/MCL.py @@ -210,6 +210,10 @@ def get_position(boxes,commande,pos): liste_y.append(y) z_t = [] + cone_x = [] + cone_y = [] + + for i in range(len(liste_x)): z_t.append((liste_x[i], liste_y[i])) @@ -223,7 +227,12 @@ def get_position(boxes,commande,pos): pos_calc[1] += pos[i][1]*W[i] pos_calc[2] += pos[i][2]*W[i] - return pos_calc, pos + for i in range(len(liste_x)): + x,y = rotation((liste_x[i] ,liste_y[i]), (0,0), pos_calc[2]) + cone_x.append(x+pos_calc[0]) + cone_y.append(y+pos_calc[1]) + + return pos_calc, pos, cone_x, cone_y '''