Skip to content

Commit 29f56bf

Browse files
committed
dumped stuff for ben for colla
1 parent 15aae77 commit 29f56bf

8 files changed

Lines changed: 2224 additions & 0 deletions

File tree

colla/README.md

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
# MiniBehavior Gridworld for CoLLA 2026
2+
3+
This directory contains the MiniBehavior gridworld environment setup for CoLLA 2026.
4+
5+
## Setup Instructions
6+
7+
### 1. Install Requirements
8+
9+
Navigate to the `colla/` directory and install the required packages:
10+
11+
```bash
12+
cd colla/
13+
pip install -r requirements.txt
14+
```
15+
16+
### 2. Run the Main Script
17+
18+
From the `colla/` directory, run:
19+
20+
```bash
21+
python main.py
22+
```
23+
(should take ~3min to complete)
24+
25+
### 3. Fix Known Package Issues
26+
27+
After installation, you may encounter two errors that require manual fixes in the installed packages:
28+
29+
#### Error 1: Gymnasium Package
30+
31+
**Location:** In your gymnasium package installation (typically in `site-packages/gymnasium/envs/registration.py`)
32+
33+
**Find this code:**
34+
```python
35+
# Update the env spec kwargs with the `make` kwargs
36+
env_spec_kwargs = copy.deepcopy(env_spec.kwargs)
37+
env_spec_kwargs.update(kwargs)
38+
```
39+
40+
**Replace with:**
41+
```python
42+
# Update the env spec kwargs with the `make` kwargs
43+
env_spec_kwargs = copy.deepcopy(env_spec.kwargs)
44+
env_spec_kwargs = {}
45+
env_spec_kwargs.update(kwargs)
46+
```
47+
48+
#### Error 2: Minigrid Environment
49+
50+
**Location:** In your minigrid package installation (typically in `site-packages/minigrid/minigrid_env.py`)
51+
52+
**Find this code:**
53+
```python
54+
assert isinstance(
55+
max_steps, int
56+
), f"The argument max_steps must be an integer, got: {type(max_steps)}"
57+
self.max_steps = max_steps
58+
```
59+
60+
**Replace with:**
61+
```python
62+
max_steps = int(max_steps)
63+
assert isinstance(
64+
max_steps, int
65+
), f"The argument max_steps must be an integer, got: {type(max_steps)}"
66+
self.max_steps = max_steps
67+
```
68+
69+
## Notes
70+
71+
- These fixes are temporary workarounds for compatibility issues between the packages
72+
- Make sure to apply these fixes in your Python environment's site-packages directory
73+
- You can find your site-packages location by running: `python -c "import site; print(site.getsitepackages())"`
74+
75+
## Output and Results
76+
77+
- The most recent frame is saved to `output_image.jpeg`
78+
- Results including NSRTs, CSVs, and logs are saved in the `results/` directory
79+
- Demos are located in `../demos/` (relative to the `colla/` directory)
80+
- To view demos, run: `python view_demos.py`
81+
82+
## Next Steps
83+
84+
1. Fix remaining MiniBehavior environments (should be 20 total)
85+
2. Implement LLM baseline operator learner
86+
3. Add predicate invention
87+
4. Generate results for CoLLA

0 commit comments

Comments
 (0)