icatcherplus / icatcher_plus

iCatcher+: Robust and automated annotation of infant gaze from videos collected in laboratory, field, and online studies
GNU General Public License v3.0
17 stars 19 forks source link

WIP/packaged results visualization UI #69

Closed deirdre-k closed 1 year ago

deirdre-k commented 1 year ago

This PR contains four main changes:

  1. Addition of web app code to src/icatcher/icatcher_app directory. This directory contains two folders, one housing all of the React-based front-end code, and the other containing a very basic flask API.
  2. A MANIFEST.in that specifies the potential location of the built React app (src/icatcher/icatcher_app/frontend/). The React build files are not visible in the repository code, but can be created by running npm build in the frontend directory.
  3. An addition to the publish.yml github workflow that adds in steps to build the React app and make the resulting build directory available to be included in the pip package.
  4. An additional script entrypoint, specified in pyproject.toml, that makes it possible for users to start up the UI by running icatcher-app in the command line

In order to be complete, this PR still needs the addition of a script to produce the necessary output to run the UI. The UI relies on having a metadata.json file and a directory of unpacked, decorated frames in order to run. I propose to add an optional iCatcher CLI flag --app that will auto-generate these outputs, as well as a script that can be run after a video is processed so that already processed videos don't necessarily need to be re-run.