Skip to content

Commit

Permalink
Refactor yolo5_simpleviz.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Samahu committed May 3, 2023
1 parent 6a0a6fb commit 30d36d1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions yolo5_simpleviz.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ def draw_results(image, objects):
def get_frame_from_scan(scan, channel):
image = scan.field(channel).astype(np.float32)
image = client.destagger(scan_capture.sensor_info, image)
post_processors[channel](image)
return image



# extract the scan width x heigh x fps information from the json file
def get_scan_size_and_fps(metadata_path):
with open(metadata_path, 'r') as file:
Expand All @@ -104,7 +104,6 @@ def process_scan(scan: LidarScan) -> LidarScan:

for f in fields:
frame = get_frame_from_scan(scan, f)
post_processors[f](frame)
results = model_infer(model, frame)
draw_results(frame, results)
# Stagger the frame again before storing the results again
Expand Down

0 comments on commit 30d36d1

Please sign in to comment.