BasisResearch / collab-creatures

Analyzing animal collaboration with Bayesian and causal inference.
4 stars 1 forks source link

Mx cleanup #10

Closed emackev closed 10 months ago

emackev commented 10 months ago

@rfl-urbaniak , This should be sufficient to generate the data you need to test the inference on communicator birds!! See Marjorie's notes on notion and slack for more info.

After the code review with Marjorie earlier today, I cleaned up some bugs, and matched params to the CVPR version, so now the histograms replicate!

Also, I tested some google drive functionality (testing_google_drive.ipynb), but haven't added that to the scripts at the moment. The folder structure is unusual (parents with ids, can'd use normal nested folder commands), so I'm not sure it's what we want, we can discuss.

@rfl-urbaniak, to generate the simulated data, run mx_refactored/generate_data_pipeline.ipynb (it doesn't take all that long). Change home_dir to where you want to save the data. Change N_runs to the number of simulations you want per condition. The current code just has 4 conditions (clustered vs distributed food; communicators vs ignorer birds). Once you generate the data, run histograms.ipynb to generate the histograms as in the poster. You'll need to switch food_statistics = 'clustered' or 'distributed'.

emackev commented 10 months ago

Consider changing bird and time indexing to start at 0 instead of 1 (0 is standard in Python). See simulation.py line 249-250, and section computing success measures within generate_data_pipeline.ipynb. Which way is Rafal's code doing?

emackev commented 10 months ago

Fixed a few more things, and ran 100 iterations of each type of simulation. @rfl-urbaniak, here's a link to the simulation results: https://drive.google.com/drive/u/0/folders/1Ef-dUtBsFFoxjadWjYLE08U0jTge-ysM

rfl-urbaniak commented 10 months ago

Consider changing bird and time indexing to start at 0 instead of 1 (0 is standard in Python). See simulation.py line 249-250, and section computing success measures within generate_data_pipeline.ipynb. Which way is Rafal's code doing?

I'm starting frames with 1, plotly animations sometimes didn't work with frames starting at 0.