A Unity3D environment for generating visual datasets to train Deep Learning models on object representation and spatial navigation tasks. The environment consists of a box with four distinctly patterned walls and a freely positionable object, and saves first-person (POV) images of an agent following a scripted trajectory.
The core idea is simple: place an agent in a controlled 3D box, vary the wall patterns and object position, and record what the agent sees as it moves. The resulting image dataset can be used to study how visual features like stripes, checkerboards, and object location are encoded — relevant to research on spatial cognition and object representation in neural networks.
The four wall patterns available are:
| Script | Pattern |
|---|---|
Checkerboard |
Checkerboard (alternating squares) |
Checkerboard H |
Horizontal stripes |
Checkerboard V |
Vertical stripes |
CheckertiltedStripes |
Angled / diagonal stripes |
Unity3D_patterned_walls/
├── Assets/ # Unity project assets (scenes, scripts, materials)
├── Packages/ # Unity package dependencies
├── ProjectSettings/ # Unity project configuration
├── UserSettings/ # Local user settings (not synced)
├── traj_obj(sh1)_20k.csv # Trajectory with object in quadrant 1
├── traj_obj(sh2)_20k.csv # Trajectory with object in quadrant 2
├── traj_obj(sh3)_20k.csv # Trajectory with object in quadrant 3
├── traj_obj(sh4)_20k.csv # Trajectory with object in quadrant 4
├── traj_wo_20k.csv # Trajectory without any object
├── .gitignore
├── .collabignore
└── LICENSE # Apache-2.0
Each .csv file contains 20,000 timesteps of agent position and heading data. The naming convention is:
traj_obj(sh1)_20k.csv— object placed in quadrant 1 of the environmenttraj_obj(sh2)_20k.csv— object placed in quadrant 2traj_obj(sh3)_20k.csv— object placed in quadrant 3traj_obj(sh4)_20k.csv— object placed in quadrant 4traj_wo_20k.csv— no object present (baseline / empty environment)
These files can be loaded into the Unity scene to replay a trajectory and capture POV images at each timestep, building a labelled image dataset.
To design a trajectory with a custom object position, use the Trajectory.py script available in the companion repository:
- Open the project in Unity3D.
- Load a trajectory
.csvfile into the scene. - Set the desired wall pattern via the appropriate script (
Checkerboard,Checkerboard H,Checkerboard V, orCheckertiltedStripes). - Position the object in the desired quadrant (or remove it for the
wobaseline). - Run the scene — the agent follows the trajectory and saves POV images as
.pngfiles at each step. - Use the resulting image dataset to train or evaluate your Deep Learning model.
- Unity3D (version used during development — check
ProjectSettings/ProjectVersion.txt) - C# (built-in with Unity)
- For trajectory generation: Python 3.x (see companion repo)
This project is licensed under the Apache License 2.0.