Ms. Pac-Man RL neuron interpretability
Collection
Neuron-level interpretability and steering of reward-trained (no imitation) Ms. Pac-Man RL agents. • 4 items • Updated
Error code: StreamingRowsError
Exception: TypeError
Message: Couldn't cast array of type
struct<fc379_ablate: struct<label: string, site: string, frac_active: double, top_state: list<item: int64>, occlusion: list<item: list<item: double>>, upstream_conv3: list<item: list<item: double>>, label_checks: struct<dir_edible_up: struct<r2_single: double, stratified_auroc: double>, n_pellets: struct<r2_single: double, stratified_auroc: null>, n_power: struct<r2_single: double, stratified_auroc: null>>, unique_r2: struct<r2_all: double, dir_edible_up: double, n_pellets: double, n_power: double>>, c3_ch3_cell00: struct<label: string, site: string, frac_active: double, top_state: list<item: int64>, occlusion: list<item: list<item: double>>, upstream_conv2: list<item: list<item: double>>>>
to
{'fc453_ablate': {'label': Value('string'), 'site': Value('string'), 'frac_active': Value('float64'), 'top_state': List(Value('int64')), 'occlusion': List(List(Value('float64'))), 'upstream_conv3': List(List(Value('float64'))), 'label_checks': {'dir_edible_up': {'r2_single': Value('float64'), 'stratified_auroc': Value('float64')}, 'n_pellets': {'r2_single': Value('float64'), 'stratified_auroc': Value('null')}, 'n_edible': {'r2_single': Value('float64'), 'stratified_auroc': Value('null')}}, 'unique_r2': {'r2_all': Value('float64'), 'dir_edible_up': Value('float64'), 'n_pellets': Value('float64'), 'n_edible': Value('float64')}}, 'c3_ch18_cell56': {'label': Value('string'), 'site': Value('string'), 'frac_active': Value('float64'), 'top_state': List(Value('int64')), 'occlusion': List(List(Value('float64'))), 'upstream_conv2': List(List(Value('float64')))}}
Traceback: Traceback (most recent call last):
File "/src/services/worker/src/worker/utils.py", line 149, in get_rows_or_raise
return get_rows(
dataset=dataset,
...<4 lines>...
column_names=column_names,
)
File "/src/libs/libcommon/src/libcommon/utils.py", line 272, in decorator
return func(*args, **kwargs)
File "/src/services/worker/src/worker/utils.py", line 129, in get_rows
rows_plus_one = list(itertools.islice(safe_iter(ds, dataset=dataset), rows_max_number + 1))
File "/src/services/worker/src/worker/utils.py", line 544, in safe_iter
yield from ds.decode(False) if ds.features else ds
File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 3052, in __iter__
for key, example in ex_iterable:
^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 2559, in __iter__
for key, pa_table in self._iter_arrow():
~~~~~~~~~~~~~~~~^^
File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 2584, in _iter_arrow
for key, pa_table in self.ex_iterable._iter_arrow():
~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 558, in _iter_arrow
for key, pa_table in iterator:
^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 440, in _iter_arrow
for key, pa_table in self.generate_tables_fn(**gen_kwags):
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/json/json.py", line 361, in _generate_tables
self._cast_table(pa_table, json_field_paths=json_field_paths),
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/json/json.py", line 132, in _cast_table
pa_table = table_cast(pa_table, self.info.features.arrow_schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2381, in table_cast
return cast_table_to_schema(table, schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2315, in cast_table_to_schema
cast_array_to_feature(
~~~~~~~~~~~~~~~~~~~~~^
table[name] if name in table_column_names else pa.array([None] * len(table), type=schema.field(name).type),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
feature,
^^^^^^^^
)
^
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 1861, in wrapper
return pa.chunked_array([func(chunk, *args, **kwargs) for chunk in array.chunks])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2161, in cast_array_to_feature
raise TypeError(f"Couldn't cast array of type\n{_short_str(array.type)}\nto\n{_short_str(feature)}")
TypeError: Couldn't cast array of type
struct<fc379_ablate: struct<label: string, site: string, frac_active: double, top_state: list<item: int64>, occlusion: list<item: list<item: double>>, upstream_conv3: list<item: list<item: double>>, label_checks: struct<dir_edible_up: struct<r2_single: double, stratified_auroc: double>, n_pellets: struct<r2_single: double, stratified_auroc: null>, n_power: struct<r2_single: double, stratified_auroc: null>>, unique_r2: struct<r2_all: double, dir_edible_up: double, n_pellets: double, n_power: double>>, c3_ch3_cell00: struct<label: string, site: string, frac_active: double, top_state: list<item: int64>, occlusion: list<item: list<item: double>>, upstream_conv2: list<item: list<item: double>>>>
to
{'fc453_ablate': {'label': Value('string'), 'site': Value('string'), 'frac_active': Value('float64'), 'top_state': List(Value('int64')), 'occlusion': List(List(Value('float64'))), 'upstream_conv3': List(List(Value('float64'))), 'label_checks': {'dir_edible_up': {'r2_single': Value('float64'), 'stratified_auroc': Value('float64')}, 'n_pellets': {'r2_single': Value('float64'), 'stratified_auroc': Value('null')}, 'n_edible': {'r2_single': Value('float64'), 'stratified_auroc': Value('null')}}, 'unique_r2': {'r2_all': Value('float64'), 'dir_edible_up': Value('float64'), 'n_pellets': Value('float64'), 'n_edible': Value('float64')}}, 'c3_ch18_cell56': {'label': Value('string'), 'site': Value('string'), 'frac_active': Value('float64'), 'top_state': List(Value('int64')), 'occlusion': List(List(Value('float64'))), 'upstream_conv2': List(List(Value('float64')))}}Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
Derived artefacts of a preregistered neuron-level interpretability and steering study of reward-trained (no imitation learning) Sample Factory APPO agents playing Atari Ms. Pac-Man.
results/*.json: every number reported in the study:site_data/*.json: per-unit data behind the interactive microscope.analysis/*.npz: unit × feature R² matrices for the agent and controls, bootstrap draws, open-loop screen maps.Top-activating frames are not stored. They are re-rendered by deterministic replay from (game seed, step) with the code at https://github.com/BurnyCoder/pacman-reinforcement-learning-neuron-mechanistic-interpretability. Agents: