bad_apple_virus icon indicating copy to clipboard operation
bad_apple_virus copied to clipboard

Improved python script

Open CoolingJam opened this issue 1 year ago • 4 comments
trafficstars

Noticed that the python script is pretty janky and fiddly, so I improved it a little by giving it a menu that gives the user a choice between converting from a video to a json file or from a json file to the bin file (no commenting needed now) and by making the script auto-create the apple_frames folder if it is missing. Also fixed a path inconsistency in the last lines of the script. Might aswell share my improvements.

CoolingJam avatar Dec 09 '23 17:12 CoolingJam

Hey, nice! Glad someone actually fixed up the python script somewhat 😅 However, this breaks my own workflow of re-running the script over and over to tweak the box generation algo. It'd be great if it had an argparse parser so I could automate it, but fall back to user-provided values otherwise.

mon avatar Dec 12 '23 03:12 mon

Sure, I'll send a commit when I have time.

CoolingJam avatar Dec 12 '23 06:12 CoolingJam

This commit should do the trick, adding an optional -i (also --input) arg, which skips the input() calls. This should make it fairly trivial to automate it with a batch script.

CoolingJam avatar Dec 13 '23 17:12 CoolingJam