carykh / PrisonersDilemmaTournament

Watch This Place's awesome video about iterated Prisoner's Dilemma for context! https://www.youtube.com/watch?v=BOvAbjfJ0x0
MIT License
205 stars 160 forks source link

Limitations on loading files? #61

Closed LegendaryHeart8 closed 3 years ago

LegendaryHeart8 commented 3 years ago

Hi! I'm currently thinking of a strategy that requires loading in a saved numpy array from a file. Are we allowed to retrieve data from a file? If so what's the maximum file size? And, how do you go about implementing this so that it works everywhere?

For me, my file should be small nothing more than a hundred kilobytes. But while implementing this I found an issue. I'm saving and loading the file within the working directory. However, I found that the working directory changes when running my strategy script and running the "prisonersDilemma.py" script. This would be solved using absolute paths but I'm not sure if that's allowed.

Wout12345 commented 3 years ago

Since you have to submit a single file in the end, I think you'll be forced to embed your data into your Python script in the end. You could automate this using a secondary Python script of course, and use a simpler set-up with imports for the time being to ease the development process ...

redtachyon2098 commented 3 years ago

Writing a file is not allowed, and like the comment above, you can't include another file with your submission. Try to find a way to make data persistent inside your code! I'm sure you can do it.

LegendaryHeart8 commented 3 years ago

Okay, thank you all!