openneuro icon indicating copy to clipboard operation
openneuro copied to clipboard

Openneuro viewer only lets you view the first few TRs

Open pjkohler opened this issue 1 year ago • 1 comments

it used to be that you could step through all of the TRs in an fMRI dataset using the left and right arrow keys, but that no longer seems to be the case. The viewer seems to update for the first few TRs, and then stops. Here is an example, in a recent dataset, but I also see it in much older data. Is there a way to view the whole data set?

pjkohler avatar Feb 28 '24 00:02 pjkohler

@pjkohler , The viewer uses Niivue, which has the ability to limit the number of preloaded volumes (aka frames). It looks like OpenNeuro have configured this to 5 volumes here. Generally, this is a good idea, and allows data to load faster in the user's browser (it spends less time downloading the entire dataset which may never be viewed).

Niivue can be configured to load all the volumes if the time series graph is shown.

@nellh and @effigies , please see this demo implementation of partially loading the first few volumes, and then allowing the full dataset to be loaded later. To load the full dataset, the graph must be visible in niivue, and the user must click on the three dots in the bottom right of the x-axis of the plot.

I would also recommend updating to the latest Niivue (0.41.1 at the time of this writing). It has a leaner package build, and many optimizations compared to your current version of 0.34.0.

The lines to add to */viewers/file-viewer-nifit.tsx are:

nv.graph.autoSizeMultiplanar = true
nv.opts.multiplanarForceRender = true
nv.graph.opacity = 1.0

the screenshot show the graph option turned on in Niivue

Screenshot 2024-04-08 at 12 20 38

hanayik avatar Apr 08 '24 11:04 hanayik