MCPcopy Create free account
hub / github.com/OpenDriveLab/TCP / save

Method save

leaderboard/team_code/tcp_agent.py:259–268  ·  view source on GitHub ↗
(self, tick_data)

Source from the content-addressed store, hash-verified

257 return control
258
259 def save(self, tick_data):
260 frame = self.step // 10
261
262 Image.fromarray(tick_data['rgb']).save(self.save_path / 'rgb' / ('%04d.png' % frame))
263
264 Image.fromarray(tick_data['bev']).save(self.save_path / 'bev' / ('%04d.png' % frame))
265
266 outfile = open(self.save_path / 'meta' / ('%04d.json' % frame), 'w')
267 json.dump(self.pid_metadata, outfile, indent=4)
268 outfile.close()
269
270 def destroy(self):
271 del self.net

Callers 2

run_stepMethod · 0.95
run_stepMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected