Skip to content

rmanaem/nerv

Repository files navigation

Neuroimaging Results Visualization


Neuroimaging Results Visualization (NeRV) is a Python-based web interface designed for visualizing neuroimaging results obtained from continuous testing of neuroimaging data across software pipelines. It utilizes Plotly Dash, Dash Bootstrap Components, and pandas to provide an interactive and informative visualization experience.
NeRV is released as a PyPI package, available here. Explore the demo and experience NeRV in action firsthand. For more information, refer to the documentation.


Getting Started

Installation

Install NeRV using pip:

pip install nerv

Example usage

In order for NeRV to generate and populate plots the underlying app requires access to the directory that houses subdirectories, which in turn contain the JSON files to be visualized. The path to directory can be passed to the app as input to the start function.

from nerv import app

app.start("path-to-data-directory")

After executing the file containing the above code snippet, a local server is started at port 8050 (by default). You can access the running NeRV application using a browser through the URL localhost:8050.

ui


Deployment

To deploy your NeRV app, you can utilize Gunicorn. Simply follow the instructions outlined in the Dash documentation here, making the necessary adjustment in the app.py module content:

app.py

from nerv import app

server = app.start("path-to-data-directory", False)

Note that when the local parameter of the start function is set to False, it will return the app.server object. This object represents the underlying Flask server that drives the Dash application. You can utilize the app.server object to customize and extend the NeRV application, going beyond the default functionality offered. For more details, refer to the Flask documentation.


License

This project is licensed under the terms of MIT License.