Coder Social home page Coder Social logo

sticky-pi-api's Introduction

The API for the Sticky Pi project

main branch: readthedocs Travis codecov

develop branch: readthedocs Travis codecov


Project organisation:

  • src a Python package (sticky_pi_api) that defines the API and its client. Complete documentation of the client and the api is available on our website.

  • server a docker-based server, deployed using docker-compose. Complete documentation here. Contains the following services:

    • db the database (MySQL)
    • api a flask server that instantiates our API and routes entry points
    • rshiny a webtool to visualise the data
    • s3 an (optional) s3 server to store and serve resources such as images (can set a remote S3 server instead)
    • nginx an server to route trafic, set subdomains, etc

sticky-pi-api's People

Contributors

qgeissmann avatar

Stargazers

Michael Bunsen avatar

Watchers

James Cloos avatar  avatar Tom X avatar Daphne Chevalier avatar

Forkers

tonyliang19

sticky-pi-api's Issues

Enable user submit by Enter key

Users should be able to submit input fields (for add row, column, edit cell) by hitting Enter, not just clicking outside.

joblib writes very many files

if we cache the md5sum computations wioth joblib, using filesystem backend, this results in at least thrice the number of files whic could be limiting (e.g. we have file number limis to 500k on ComputeCanada ๐Ÿคฆ )

Special coordinate columns

Special metadata columns lat, lng may exist with these names.

  • Users should not be allowed to chose these names
  • these names should be mapped lng: Longitude,... for display.
  • Column types drop down should only offer these types when they are not already defined

Site greying out on downloading single images

after clicking opened(in modal) thumbnail and successfully downloading image from server(ComputeCanada) link, browser console: this.$socket is null, modal buttons don't work and cannot re-invoke any new thumbnail modals/popup from timeline anymore

  • R Shiny Apps Greys Out and Hangs
    perhaps some safety feature of Shiny site-serving: grey out when unrecognized interruption to connection, e.g. visiting external link
    -> maybe HTML element external links will all break Shiny webapp? for any downloads can only use Shiny's download buttons?
    -> site also grey out when invalid user/login, but can't interact with anything

Improve query performance

It takes too long to simply query image series:

time curl --user XXXXXXX:XXXXXXXXXXX -X POST -H "Content-Type: application/json" -d '[{"start_datetime": "2020-06-01_00-00-00", "end_datetime": "2030-01-01_00-00-00", "device": "%"}]' https://api.sticky-pi.com/get_image_series/image > /dev/null takes 20s on the host that is for ~75k images (URL pre-cached)

https://stackoverflow.com/questions/23185319/why-is-loading-sqlalchemy-objects-via-the-orm-5-8x-slower-than-rows-via-a-raw-my
https://stackoverflow.com/questions/31387980/better-understand-sqlalchemys-yield-per-problems

needs profiling, but it looks like it is due to the use of ORM and how we generate output json (Base.to_dict)

project cell editing content checking

ATM, when editing a cell with an erroneous value e.g. "a" for a numerical column, the server API responds with an error, and shiny crashes with no explanation. We could:

  • Check format before sending
  • Display an error message when an unknown server error prevented cell edition

User edits to projects metadata table not being saved

After editing a cell of the projects table, the new value is shown (also after clicking away on the side), until the user interacts with any of the DataTable widget. Then, the app seems to refetch the table and the original value at startup is shown again.

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.