cRz-Shadows / Pokemon_Trainer_Tournament_Simulator

Here we have an environment for running large amounts of Pokémon battle simulations in the command line.
55 stars 3 forks source link

runSimulations.py creating an empty "output.txt" file #5

Closed obaming closed 2 weeks ago

obaming commented 2 weeks ago

So, after fixing all the paths in the code, I was able to run the code successfully, and the program creates an "output.txt" file. However, it's always empty. I've tried with both my own combinations and the ones provided in the "videos" folder and none of them work. What could be happening here?

cRz-Shadows commented 2 weeks ago

Check the worker outputs to see if they have outputs, otherwise you've probably messed something up when "fixing" all the paths in the code. They shouldn't really have needed changed unless you changed some filenames from default though.

obaming commented 2 weeks ago

I've checked the worked outputs and it's printing txt files with the same numbers of threads I chose, but the output.txt is still empty. Also, I'm sorry if "fixing" was the wrong term as I am not a native english speaker, by "fixing" I meant I just changed the file name to the be the same as the json ones. It's still not working, so I probably messed up there, so I'll try to install this again and start from zero and see if it works.

obaming commented 2 weeks ago

Alright, I think I found the thing I messed up: #read in teams with open('Inputs/tournament_battles.json', 'r') as infile: teams = json.load(infile)

Am I supposed to create this "tournament_battles.json" file?

cRz-Shadows commented 2 weeks ago

BuildBattles.py does that, are you not following the instructions in manual.md?

obaming commented 2 weeks ago

Somehow I forgot to run BuildBattles.py, it's now working fine! Thank you so much for your patience and for helping me!