urban-toolkit / curio

Curio: A Dataflow-Based Framework for Collaborative Urban Visual Analytics

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Curio

Curio Logo

Curio is a framework for collaborative urban visual analytics that uses a dataflow model with multiple abstraction levels (code, grammar, GUI elements) to facilitate collaboration across the design and implementation of visual analytics components. The framework allows experts to intertwine preprocessing, managing, and visualization stages while tracking provenance of code and visualizations.

Curio: A Dataflow-Based Framework for Collaborative Urban Visual Analytics
Gustavo Moreira, Maryam Hosseini, Carolina Veiga, Lucas Alexandre, Nico Colaninno, Daniel de Oliveira, Nivan Ferreira, Marcos Lage, Fabio Miranda

Video:

curio_compressed_720.mp4

Curio Use Cases

Table of contents

  1. Features
  2. Installation and quick start
    1. Curio Backend
    2. Python sandbox
    3. UTK workflow
    4. Curio frontend
    5. Ray tracing
  3. First dataflow
  4. Team

Features

  • Provenance-aware dataflow
  • Modularized and collaborative visual analytics
  • Support for 2D and 3D maps
  • Linked data-driven interactions
  • Integration with UTK and Vega-Lite

Installation and quick start

Because Curio is integrated with UTK it is necessary to add it as a submodule.

git clone git@github.com:urban-toolkit/curio.git  
git submodule init
git submodule update --remote --merge

Curio is divided into three components: backend (provenance and database management), python sandbox (to run python code), and the front-end. All component need to be running.

Curio was tested on Windows 11 and MacOS Sonoma 14.5.

Python >= 3.9 is needed.

Curio Backend

The backend source code is available on the backend folder. It is recommended to install its requirements on a virtual environment such as Anaconda. Inside the backend folder:

pip install -r requirements.txt

Once requirements are installed we have to create a SQLite database for provenance.

python create_provenance_db.py

Now the backend server can be started.

python server.py

The backend is also responsible for user authentication. To manage migrations:

  • Create migration
# after update any model, run it to generate a new migration
FLASK_APP=server.py flask db migrate -m "Migration Name"
  • Apply migrations
# run it to apply any migration that hasn't run yet
FLASK_APP=server.py flask db upgrade

Python sandbox

Since modules on Curio can run Python code. It is necessary to run a Python sandbox. On sandbox folder.

To run without Docker (Anaconda environment recommended):

pip install -r requirements.txt

Installing UTK's backend module to have access inside the sandbox:

pip install utk-0.8.9.tar.gz

Run the server:

python server.py

If you prefer to use Docker (can't use GPU for Ray Tracing):

docker-compose up

UTK workflow

Because Curio also uses UTK's frontend it is necessary to compile the UTK submodule. On utk-workflow folder:

cd src/utk-ts

NodeJS is needed to build the frontend. Anaconda is recommended:

npm install
npm run build 

Curio frontend

To start Curio's frontend. Simply go urban-workflows and run:

npm install
npm run build
npm run start

Ray tracing

To use Ray Tracing from UTK's python module please consult UTK's requirements.

First dataflow

For a simple introductory example check this tutorial.

Tutorial

Team

Gustavo Moreira (UIC)
Maryam Hosseini (MIT)
Carolina Veiga (UIUC)
Lucas Alexandre (UFF)
Nico Colaninno (Polimi)
Daniel de Oliveira (UFF)
Nivan Ferreira (UFPE)
Marcos Lage (UFF)
Fabio Miranda (UIC)

About

Curio: A Dataflow-Based Framework for Collaborative Urban Visual Analytics

License:MIT License


Languages

Language:TypeScript 80.9%Language:Python 18.3%Language:CSS 0.3%Language:JavaScript 0.2%Language:Mako 0.1%Language:HTML 0.1%Language:Dockerfile 0.1%