continual-foragax 0.37.0__tar.gz → 0.39.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/PKG-INFO +1 -1
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/pyproject.toml +2 -2
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/PKG-INFO +1 -1
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/env.py +46 -11
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/registry.py +18 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/tests/test_foragax.py +9 -6
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/README.md +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/setup.cfg +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/SOURCES.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/dependency_links.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/entry_points.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/requires.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/top_level.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/__init__.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/colors.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID100897.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID100928.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID100929.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID100930.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID100931.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106714.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106715.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106716.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106717.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106718.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106930.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106931.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106932.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106933.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106934.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106935.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106936.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106937.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106938.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106939.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106940.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106941.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106942.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106943.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106994.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106995.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106996.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106997.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106998.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID106999.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107000.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107001.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107002.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107003.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107004.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107005.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107006.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107007.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107008.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107009.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107010.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107011.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107012.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107013.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107014.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107015.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107016.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107017.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107018.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107019.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107020.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107021.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107022.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107023.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107024.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107025.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107026.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107027.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107028.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107029.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107030.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107031.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107032.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107033.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107034.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107035.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107036.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107037.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107038.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107039.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107040.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107041.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107042.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107043.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107044.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107045.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107046.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107047.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107048.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107049.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107050.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107051.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107052.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107053.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107054.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107055.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107056.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107057.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107058.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107059.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107060.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107061.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107062.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107063.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107064.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107065.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107066.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107067.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107068.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107069.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107070.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID107071.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID115808.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID115812.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID146811.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156831.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156835.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156839.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156843.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156847.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156851.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156855.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156859.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156863.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156867.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156871.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156875.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156879.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156883.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/TG_SOUID156887.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/elements.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/metadata.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/data/ECA_non-blended_custom/sources.txt +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/objects.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/rendering.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/foragax/weather.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/tests/test_benchmark.py +0 -0
- {continual_foragax-0.37.0 → continual_foragax-0.39.0}/tests/test_registry.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "continual-foragax"
|
|
3
|
-
version = "0.
|
|
3
|
+
version = "0.39.0"
|
|
4
4
|
description = "A continual reinforcement learning benchmark"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
authors = [
|
|
@@ -30,7 +30,7 @@ build-backend = "setuptools.build_meta"
|
|
|
30
30
|
[tool]
|
|
31
31
|
[tool.commitizen]
|
|
32
32
|
name = "cz_conventional_commits"
|
|
33
|
-
version = "0.
|
|
33
|
+
version = "0.39.0"
|
|
34
34
|
tag_format = "$version"
|
|
35
35
|
version_files = ["pyproject.toml"]
|
|
36
36
|
|
|
@@ -132,6 +132,7 @@ class ForagaxEnv(environment.Environment):
|
|
|
132
132
|
observation_type: str = "object",
|
|
133
133
|
dynamic_biomes: bool = False,
|
|
134
134
|
biome_consumption_threshold: float = 0.9,
|
|
135
|
+
dynamic_biome_spawn_empty: float = 0.0,
|
|
135
136
|
max_expiries_per_step: int = 1,
|
|
136
137
|
):
|
|
137
138
|
super().__init__()
|
|
@@ -156,6 +157,7 @@ class ForagaxEnv(environment.Environment):
|
|
|
156
157
|
self.teleport_interval = teleport_interval
|
|
157
158
|
self.dynamic_biomes = dynamic_biomes
|
|
158
159
|
self.biome_consumption_threshold = biome_consumption_threshold
|
|
160
|
+
self.dynamic_biome_spawn_empty = dynamic_biome_spawn_empty
|
|
159
161
|
if max_expiries_per_step < 1:
|
|
160
162
|
raise ValueError("max_expiries_per_step must be at least 1")
|
|
161
163
|
self.max_expiries_per_step = max_expiries_per_step
|
|
@@ -772,20 +774,53 @@ class ForagaxEnv(environment.Environment):
|
|
|
772
774
|
biome_mask = self.biome_masks_array[i]
|
|
773
775
|
new_gen_value = new_biome_state.generation[i]
|
|
774
776
|
|
|
775
|
-
#
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
777
|
+
# Update mask: biome area AND needs respawn
|
|
778
|
+
should_update = biome_mask & should_respawn[i][..., None]
|
|
779
|
+
|
|
780
|
+
# 1. Merge: Overwrite with new objects if present, otherwise keep existing
|
|
781
|
+
# If the new spawn has an object, we take it. If it's empty, we keep whatever was there.
|
|
782
|
+
new_spawn_valid = all_new_objects[i] > 0
|
|
779
783
|
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
784
|
+
merged_objs = jnp.where(new_spawn_valid, all_new_objects[i], new_obj_id)
|
|
785
|
+
merged_colors = jnp.where(
|
|
786
|
+
new_spawn_valid[..., None], all_new_colors[i], new_color
|
|
783
787
|
)
|
|
784
|
-
|
|
785
|
-
|
|
788
|
+
merged_params = jnp.where(
|
|
789
|
+
new_spawn_valid[..., None], all_new_params[i], new_params
|
|
786
790
|
)
|
|
787
|
-
|
|
788
|
-
|
|
791
|
+
|
|
792
|
+
# For generation/spawn time, update only if we took the NEW object
|
|
793
|
+
merged_gen = jnp.where(new_spawn_valid, new_gen_value, new_gen)
|
|
794
|
+
merged_spawn = jnp.where(new_spawn_valid, current_time, new_spawn)
|
|
795
|
+
|
|
796
|
+
# 2. Apply dropout to the MERGED result (only where we are allowed to update)
|
|
797
|
+
if self.dynamic_biome_spawn_empty > 0:
|
|
798
|
+
key, dropout_key = jax.random.split(key)
|
|
799
|
+
# Dropout applies only to cells that are both in the biome AND need updating
|
|
800
|
+
keep_mask = jax.random.bernoulli(
|
|
801
|
+
dropout_key, 1.0 - self.dynamic_biome_spawn_empty, merged_objs.shape
|
|
802
|
+
)
|
|
803
|
+
# Only apply dropout where should_update is true; elsewhere, keep merged_objs
|
|
804
|
+
dropout_mask = should_update & keep_mask
|
|
805
|
+
# Apply dropout only to the merged result and associated metadata
|
|
806
|
+
final_objs = jnp.where(dropout_mask, merged_objs, 0)
|
|
807
|
+
final_colors = jnp.where(dropout_mask[..., None], merged_colors, 0)
|
|
808
|
+
final_params = jnp.where(dropout_mask[..., None], merged_params, 0)
|
|
809
|
+
final_gen = jnp.where(dropout_mask, merged_gen, 0)
|
|
810
|
+
final_spawn = jnp.where(dropout_mask, merged_spawn, 0)
|
|
811
|
+
else:
|
|
812
|
+
final_objs = merged_objs
|
|
813
|
+
final_colors = merged_colors
|
|
814
|
+
final_params = merged_params
|
|
815
|
+
final_gen = merged_gen
|
|
816
|
+
final_spawn = merged_spawn
|
|
817
|
+
|
|
818
|
+
# 3. Write back: Only update where should_update is true
|
|
819
|
+
new_obj_id = jnp.where(should_update, final_objs, new_obj_id)
|
|
820
|
+
new_color = jnp.where(should_update[..., None], final_colors, new_color)
|
|
821
|
+
new_params = jnp.where(should_update[..., None], final_params, new_params)
|
|
822
|
+
new_gen = jnp.where(should_update, final_gen, new_gen)
|
|
823
|
+
new_spawn = jnp.where(should_update, final_spawn, new_spawn)
|
|
789
824
|
|
|
790
825
|
# Clear timers in respawning biomes
|
|
791
826
|
new_respawn_timer = object_state.respawn_timer
|
|
@@ -143,6 +143,17 @@ ENV_CONFIGS: Dict[str, Dict[str, Any]] = {
|
|
|
143
143
|
"dynamic_biomes": True,
|
|
144
144
|
"biome_consumption_threshold": 1000,
|
|
145
145
|
},
|
|
146
|
+
"ForagaxDiwali-v5": {
|
|
147
|
+
"size": (15, 15),
|
|
148
|
+
"aperture_size": None,
|
|
149
|
+
"objects": None,
|
|
150
|
+
"biomes": (Biome(start=(0, 0), stop=(15, 15), object_frequencies=(0.4,)),),
|
|
151
|
+
"nowrap": False,
|
|
152
|
+
"deterministic_spawn": True,
|
|
153
|
+
"dynamic_biomes": True,
|
|
154
|
+
"biome_consumption_threshold": 1000,
|
|
155
|
+
"dynamic_biome_spawn_empty": 0.4,
|
|
156
|
+
},
|
|
146
157
|
"ForagaxTwoBiome-v1": {
|
|
147
158
|
"size": (15, 15),
|
|
148
159
|
"aperture_size": None,
|
|
@@ -597,6 +608,13 @@ def make(
|
|
|
597
608
|
regen_delay=(9, 11),
|
|
598
609
|
reward_repeat=100,
|
|
599
610
|
)
|
|
611
|
+
if env_id == "ForagaxDiwali-v5":
|
|
612
|
+
config["objects"] = create_fourier_objects(
|
|
613
|
+
num_fourier_terms=10,
|
|
614
|
+
reward_delay=reward_delay,
|
|
615
|
+
regen_delay=(9, 11),
|
|
616
|
+
reward_repeat=100,
|
|
617
|
+
)[:1]
|
|
600
618
|
|
|
601
619
|
if env_id == "ForagaxSineTwoBiome-v1":
|
|
602
620
|
biome1_oyster, biome1_deathcap, biome2_oyster, biome2_deathcap = (
|
|
@@ -2811,13 +2811,14 @@ def test_fourier_reward_mathematical_properties():
|
|
|
2811
2811
|
key = jax.random.key(42)
|
|
2812
2812
|
|
|
2813
2813
|
# Create a simple single-term Fourier series: a1*cos(t) + b1*sin(t)
|
|
2814
|
+
# We use period=8.0 so that clock=1 corresponds to phase 2π/8 = π/4
|
|
2814
2815
|
simple_params = jnp.array(
|
|
2815
2816
|
[
|
|
2816
|
-
|
|
2817
|
+
8.0, # period
|
|
2817
2818
|
-1.0,
|
|
2818
|
-
1.0, #
|
|
2819
|
+
1.0, # min=-1, max=1
|
|
2819
2820
|
0.5,
|
|
2820
|
-
0.5, # a1=0.5, b1=0.5
|
|
2821
|
+
0.5, # a1=0.5, b1=0.5
|
|
2821
2822
|
0.0,
|
|
2822
2823
|
0.0,
|
|
2823
2824
|
0.0,
|
|
@@ -2828,7 +2829,8 @@ def test_fourier_reward_mathematical_properties():
|
|
|
2828
2829
|
dtype=jnp.float32,
|
|
2829
2830
|
)
|
|
2830
2831
|
|
|
2831
|
-
# At t=0
|
|
2832
|
+
# At t=0 (clock=0): phase=0
|
|
2833
|
+
# 0.5*(cos(0) + sin(0)) = 0.5*(1 + 0) = 0.5
|
|
2832
2834
|
reward_t0_simple = fourier_obj.reward(0, key, simple_params)
|
|
2833
2835
|
# The actual reward is normalized: 2*(raw - min)/(max - min) - 1, then * base_magnitude
|
|
2834
2836
|
# raw = 0.5, min=-1, max=1, so: 2*(0.5 - (-1))/(1 - (-1)) - 1 = 2*(1.5)/2 - 1 = 1.5 - 1 = 0.5
|
|
@@ -2837,9 +2839,10 @@ def test_fourier_reward_mathematical_properties():
|
|
|
2837
2839
|
f"Expected ~1.0, got {reward_t0_simple}"
|
|
2838
2840
|
)
|
|
2839
2841
|
|
|
2840
|
-
# At t
|
|
2842
|
+
# At t=1 (clock=1): phase = 2π * 1/8 = π/4
|
|
2843
|
+
# 0.5*(cos(π/4) + sin(π/4)) = 0.5*(0.707 + 0.707) = 0.5*1.414 ≈ 0.707
|
|
2844
|
+
reward_t_quarter = fourier_obj.reward(1, key, simple_params)
|
|
2841
2845
|
t_quarter = jnp.pi / 4
|
|
2842
|
-
reward_t_quarter = fourier_obj.reward(t_quarter, key, simple_params)
|
|
2843
2846
|
raw_quarter = 0.5 * (jnp.cos(t_quarter) + jnp.sin(t_quarter))
|
|
2844
2847
|
expected_quarter = (
|
|
2845
2848
|
2 * (raw_quarter - (-1)) / (1 - (-1)) - 1
|
|
File without changes
|
|
File without changes
|
{continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/requires.txt
RENAMED
|
File without changes
|
{continual_foragax-0.37.0 → continual_foragax-0.39.0}/src/continual_foragax.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|