GithubHelp home page GithubHelp logo

tony32769 / bokeh_light_curve_inspector Goto Github PK

View Code? Open in Web Editor NEW

This project forked from phuijse/bokeh_light_curve_inspector

0.0 2.0 0.0 217 KB

A simple pure-python web browser application using Bokeh to visualize, inspect and label periodic astronomical time series

License: MIT License

Python 100.00%

bokeh_light_curve_inspector's Introduction

Bokeh Light Curve Inspector

A simple pure-python web browser application using Bokeh (bokeh.pydata.org) to visualize, inspect and label periodic astronomical time series. Possible use-cases are novelty detection, collaborative research and crowd-sourcing. Disclaimer: This code was written for educative purposes and it is not safe for production (see TODO below).

How to run

cd this_folder
mkdir example/results
bokeh serve . --args example/light_curves example/periods.pkl example/results

Then point your favorite web browser to

http://localhost:5006

Note about the arguments

The Bokeh server allows to pass arguments to the main code using the --args flag. Three arguments are expected:

  1. Path to the folder containing the light curve files
  2. Path to a pickle file containing file names and light curve periods
  3. Path to a folder to dump results from labeling process

Reading and parsing of the light curve files is done in light_curve_handler.py

What you should see when running the example

Log-in interface:

Log-in interface

Inspector interface:

Inspector interface

How does it work

  • Choose a username and hit enter at the log-in interface
  • You should be seeing the inspector interface. Here you can:
    • Move from page to page, each showing a set of 9 light curves
    • Label the currently selected light curve into one of the available categories
    • Each time you move to the next/previous page your labeling results are saved at resultfolder/username/

Remote access to the bokeh server

If you intend to access the bokeh server from another machine in your LAN you will have to add

--allow-websocket-origin=myserverlanip:5006

before --args in the execution line above

If you intend to access from outside your LAN just change myserverlanip by the desired domain. Bokeh serve also accepts a --port option if you need to use a different port

Requirements

  1. Numpy (numpy.org)
  2. Bokeh (bokeh.pydata.org)

Note: Tested with Python 3.6 and Bokeh 0.12.6

TODO

  • Add test data
  • Improve server security to make this safe for production
  • Add user authentication, sessions, etc

License

MIT

bokeh_light_curve_inspector's People

Contributors

phuijse avatar

Watchers

 avatar  avatar

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.