Skip to content

Make some fields of the Info object read-only and auto-generated #2300

@wmvanvliet

Description

@wmvanvliet

it would be nice if info['nchans'] would be read only and internally map to len(info['chs']). The same with info['ch_names'], which should map internally to [ch['name'] for ch in info['chs']]. This would reduce the chances of having inconsistent data and help with the DRY.

This would involve overwriting the __get_item__ and __set_item__ methods.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions