Skip to content

Repository files navigation

Welcome to CosmoVis!

screenshot of cosmovis

We introduce CosmoVis, an open-source web-based astrophysics visualization tool that facilitates the interactive analysis of large-scale hydrodynamic cosmological simulation datasets. CosmoVis enables astrophysicists as well as citizen scientists to share and explore these datasets, which are often comprised of complex, unwieldy data structures greater that 1 TB in size. Our tool visualizes a range of salient gas, dark matter, and stellar attributes extracted from the source simulations, and enables further analysis of the data using observational analogues, specifically absorption line spectroscopy. CosmoVis introduces novel analysis functionality through the use of virtual skewers that define a sightline through the volume to quickly obtain detailed diagnostics about the gaseous medium along the path of the skewer, including synthetic spectra that can be used to make direct comparisons with observational datasets. We identify the main analysis tasks that CosmoVis enables, and evaluate the software by presenting a series of contemporary scientific use cases that utilize CosmoVis. Additionally, we conduct a series of task-based interviews with astrophysicists indicating the usefulness of CosmoVis for a range of data analysis tasks.

A live demo can be found here: CosmoVis

A dev demo with experimental features can be found here: CosmoVis

Here is a video that outlines a scientific use case from CosmoVis: link

Installation Instructions

CosmoVis can be configured to run locally or remotely on a server, but the most simple way is to have it run locally. Hosting has the benefit of being able to access the visualization from other devices, and only takes a few extra steps to configure. CosmoVis has been tested on Windows, Linux and Mac.

To get started, install Python 3.7+ if you do not have it already (CosmoVis was built with version 3.8.5). It is helpful to create a new environment using Conda, but it is not necessary. There are a few specific Python packages that need to be installed:

$ pip install eventlet==0.25.2 Flask==1.1.2 Flask-SocketIO==4.3.0 Frozen-Flask==0.15 python-engineio==3.13.0 python-socketio==5.6.0 mpi4py numpy cython git

Note: in order to install mpi4py, you may need to install a version of MPI on your machine, such as OpenMPI.

In addition, the development versions of yt, trident and yt-astro-analysis must be installed (in that order):

$ git clone https://github.com/yt-project/yt.git yt
$ cd yt
$ pip install -e .
$ cd ..
$ git clone https://github.com/trident-project/trident.git trident
$ cd trident
$ pip install -e .
$ cd ..
$ git clone https://github.com/yt-project/yt_astro_analysis.git yt_astro_analysis
$ cd yt_astro_analysis
$ pip install -e .
$ cd ..

To finish installing Trident, open Python in the terminal and import Trident.

$ python
> import trident

The first time Trident runs an installation dialogue appears. Follow the on screen instructions and verify that is has been installed successfully by typing:

> trident.verify()

Alternatively, one can use the included requirements.txt file to install Python dependencies:

`pip install -r requirements.txt`

Running CosmoVis

  • In the terminal, cd into the CosmoVis folder and type python cosmo-serv.py
  • Once the application starts, wait for the data to finish loading and in the web browser go to localhost:5000
  • If the webpage does not load, try doing a hard refresh of the page (cmd+shft+R on Mac or ctrl+shft+r on Windows) as it may take a moment to first display.

Usage

  • CosmoVis enables real time volume rendering in the web browser. Try it out by clicking and dragging within the visualization. Use your mouse or trackpad scrolling to zoom in and out of the simulation.
  • On the right, click on the "data selection" to open a panel that allows for switching between simulations, changing the resolution, and slicing the volume.

Available Cosmological Simulation Particle Types and Fields

Example particle types and fields made available in cosmological simulation snapshots that can be retrieved and plotted using CosmoVis. Simulation datasets typically organize their data in terms of differentparticle types (gas, dark matter, stars, and black holes), each expressinga variety of physical quantity fields.

Particle TypeFieldsIllustris (2013)EAGLE (2017)IllustrisTNG (2018)
GasAGN Radiation (Bolometric intensity)xx
Center Of Massx
Cooling Ratexx
Coordinatesxxx
Densityxxx
Electron Abundancexx
Element/Metal Abundancesxx
Energy Dissipationx
Entropyx
Expansion Factor at Maximum Temperaturex
Gravitational Potential Energyxx
Host Halo Massxx
GroupNumberx
Host Halo TVir Massx
Internal Energyxxx
InternalEnergyOldx
Iron Mass Frac From SNIax
Mach Numberx
Magnetic Fieldx
Magnetic Field Divergencex
Massxxx
Maximum Temperaturex
Metal Mass Frac From AGB, SNII and SNIa Starsx
Metallicityxxx
Metalsx
Metals Taggedx
Metal Mass Frac From SNIIx
Metal Mass Frac From SNIax
Neutral Hydrogen Abundancexx
NumTracersx
OnEquationOfStatex
ParticleIDsxxx
Smoothed Element Abundancex
Smoothed Iron Mass Frac From SNIax
Smoothed Metallicityx
SmoothingLengthxx
Star Formation Ratexxx
Subfind DM Densityx
Subfind Densityxx
Subfind Hsmlxx
Subfind Vel Dispxx
Sub Group Numberx
Temperaturex
Total Mass From AGB, SNII and SNIa Starsx
Total Mass From SNIIx
Total Mass From SNIax
Velocityxxx
Volumex
Wind Dark Matter Velocity Dispersionxx
Dark matterCoordinatesxxx
GroupNumberx
ParticleIDsxxx
Potentialxx
Subfind DM Densityx
Subfind Densityxx
Subfind Hsmlxx
Subfind Vel Dispxx
SubGroupNumberx
Velocityxxx
Star particlesBirth Densityx
Birth Positionx
Birth Velocityx
Coordinatesxxx
Element/Metal Abundancesxx
Expansion Factor at Maximum Temperaturex
Feedback Energy Fractionx
GroupNumberx
Host Halo TVir Massx
Initial Massxxx
Iron Mass Frac From SNIax
Massxxx
Maximum Temperaturex
Metal Mass Frac From AGB, SNII and SNIa Starsx
Metal Mass Frac From SNIIx
Metal Mass Frac From SNIax
Metallicityxxx
Metalsx
Metals Taggedx
Number of Tracersx
ParticleIDsxx
Potentialxx
Previous Stellar Enrichmentx
Smoothed Element Abundancex
Smoothed Iron Mass Frac From SNIax
Smoothed Metallicityx
Smoothing Lengthx
Stellar Enrichment Counterx
Stellar Formation Timexxx
Stellar Photometricsxx
Stellar Hsmlx
Subfind DM Densityx
Subfind Densityxx
Subfind Hsmlxx
Subfind Vel Dispxx
SubGroupNumberx
Total Mass From AGB, SNII and SNIa Starsx
Total Mass From SNIIx
Total Mass From SNIax
Velocityxxx
Black holesBlack Hole Massxxx
Black Hole Mass Accretion Ratexxx
Bondi Accretion Ratex
Coordinatesxxx
Cumulative Thermal/Kinetic AGN Energy Injectionxx
BH_CumEgyInjection_RMx
Cumulative Accreted Massxxx
Cumulative Number of BH Seeds Swallowedx
BH_CumMassGrowth_QMxx
BH_CumMassGrowth_RMx
Densityxxx
Eddington Accretion Ratex
Expansion Factor When BH last accreted another BHx
Formation Timex
Gravitational Potentialxx
Host Halo Massxxx
BH_Hsmlxx
BH_Mass_bubblesx
BH_Mass_inix
BH MostMassiveProgenitorIDx
Massxxx
Mean Magnetic Pressurex
Number of Black Hole Mergersxx
Number of Tracersx
Pressurexxx
Sound Speedx
Surrounding Gas Velocityx
GroupNumberx
ParticleIDsxxx
Smoothing Lengthx
Subfind DM Densityx
Subfind Densityxx
Subfind Hsmlxx
Subfind Vel Dispxx
Thermal Energy in QSO-Heated Bubblesxx
SubGroupNumberx
Velocityxxx

Releases

Packages

Contributors

Languages