donadigo / TMTrackNN

Building TrackMania tracks with neural networks.
GNU General Public License v3.0
88 stars 6 forks source link

fixed block processing not cutting off after the ghost has finished #13

Closed JackOE3 closed 11 months ago

JackOE3 commented 11 months ago

process_blocks inside preprocessing.py now compares the time of the sample record against the race_time of the replay and and returns as soon as that time is reached

donadigo commented 11 months ago

Is there any reason why ghost.records cannot be cut off before doing anything first and then all of the other code follows unchanged?

finish_index = int(ghost.race_time / 100)
for idx, record in enumerate(ghost.records[:finish_index]):