0

This is a question about the Allen Brain Observatory API.

I am trying to find both the ROI mask and L0 regularization events for each cell in a particular experiment. I know how to get the ROI mask information given a particular cell ID, but I don't know how to get the L0 regularization events. As far as I can tell, the return value of get_ophys_experiment_events() is an [N_cells,N_times]-sized array with no information about particular cell IDs.

I've looked through the API and done some googling and haven't found anything.

The following code gets the ROI mask for the first cell in a particular experiment:

from allensdk.core.brain_observatory_cache import BrainObservatoryCache

boc = BrainObservatoryCache(manifest_file='boc/manifest.json')

data_set = boc.get_ophys_experiment_data(510221121)

cid = data_set.get_cell_specimen_ids()[0]

roi_mask = data_set.get_roi_mask(cell_specimen_ids=[cid])

The following code gets the events associated with the same experiment:

events = boc.get_ophys_experiment_events(ophys_experiment_id=510221121)

However, I don't know which row in the events variable corresponds to the ID stored in cid.

Is there a way to do this?

elliotc12
  • 3
  • 3

1 Answers1

0

A similar question has been answered in the Allen Brain Map Community Forum https://community.brain-map.org/t/how-can-i-get-the-l0-regularization-events-for-a-specific-cell-id/261

  • While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. – Andrey Belykh Sep 09 '19 at 15:59