Giter VIP home page Giter VIP logo

assai's Introduction

ASsAI

We call it the Advanced Spectral Analysis Interface, assai -- pronounced as the brazilian fruit açaí, in honour to my supervisor, passionate about it; He has a point.

The tool in its full capabilities is meant to be an interactive interface to explore photometric data available through the VO network in the format of a spectral energy distribution plot.

Nevertheless, the tool also provide the query-only interface for the user not interested in graphical outputs.

Run

$ python assai.py

A new file assai.html is created and a web browser window/tab should open rendering it.

Howto add a resource/catalog

assai reads the catalog services defined in $ASSAI_DATA, where each service is defined by a json file or python package.

The json file is the simplest way to insert a VO-SCS service: we define the source URL, columns of interest and respective wavelength:

{
  "url": "https://vo.service.net/scs.xml?",
  "column_names": ["RA", "Dec", "Flux_a", "Flux_b", "Flag_q"],
  "column_units": ["deg", "deg", "erg s-1 cm-2", "erg s-1 cm-2", ""],

  "wavelength": {
	"Flux_a": "500nm",
	"Flux_b": "5keV"
  }
}

-- /.\

assai's People

Contributors

chbrandt avatar

Watchers

 avatar  avatar  avatar

assai's Issues

Implement high-level equations interface

To simplify the units conversion interface -- between the data input and the sed/output (erg/s/cm2) -- a less programmatic (or python programming) interaction with the user is very welcome.

Context

Take for example the sdss catalog entry (assai/catalogs/sdss/): in the filters.py module, a set of equations define how to convert SDSS' nanomaggies to erg/s/cm2. It is a python module (working like plugin) where functions flux_density and wavelength must be defined -- catalogs/filters.py expect those functions to be defined as well as the filters dictionary

Problem

Too technical, too delicate. Besides the necessity of knowing the python language, the user is very much prone to errors; the structure in place is very specific.

Alternatives

Ideally, the user will have to define a flux-density expression in a simple pseudo-code. Something like it would be done in Mathematica, Maple, Latex, for example. If one simple equation is all it takes to convert the "whatever-units" to erg/s/cm2, great, but expression can be a system of equations also.

We cannot though accept freely equations/expressions given by the user and simply eval, this is clearly unsafe; We must apply some parsing and/or use a restricted framework. The following may help find the solution:

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.