Skip to content

IgnacioPasamontes/flame_example

Repository files navigation

Flame_service

OpenAPI 3 definition for flame and django rest framework implementation.

Installation

Flame should have been already installed in this computer. Refer to the flame manual for full instructions of how create a flame conda environment and install the software.

Start activating the flame environment typing:

source activate flame (in Linux)
activate flame (in Windows)

Download the repository:

git clone https://github.com/phi-grib/flame_service.git

Go to the source repository directory

cd flame_API/flame_api

Configure files and paths:

In the nginx-app.conf, supervisor-app.conf and uwsgi.ini replace {ABSOLUTE_PROJECT_PATH} string with the absolute path of the project and {ENVIRONMENT_PATH_FLAME} string with the absolute path of the flame enviroment files. E.g.

nginx supervisor uwsgi

Create the folder 'var/run/nginx/' in your flame enviroment.

mkdir /home/$user/$conda/envs/flame/var/run/nginx/

RUN

supervisord -c supervisor-app.conf

Then, open a browser and type the address http://localhost:8000

Flame GUI

The flame GUI consist in 2 main areas: control area and visualization area.

Control area has all functions needed. Those functions are distributed in three tabs (Manage, Build and Predict). The Manage tab is responsible for managing the models: create, delete, import and export. Build and Predict tabs are teh responsible to create and predict models. In both tabs, the sequence is always the same:

  • First we have to select a model
  • Next step is select a training or prediction set
  • Select the parameters desired in case of construction.
  • And finally, throw the prediction or build the model.

Screenshots

Areas: Areas Predict Manage Build Data training uploader Validation Results Prediction Results

flame API design explanation

Here I'll use the base URL to be api.flame.edu/v1/ as a placeholder for the future (no yet created) base URL that respects the consortium specs.

For sake of simplicity and guiven the architecture of flame this API uses 3 roots:

/manage
/build
/predict

Each model is a resource that the client can create, modify, delete or exploit so the url structure will be:

api.flame.edu/v1/{root}/models/{modelname}

Over this resource the client can create, delete or get info with the HTTP verbs (POST, DELETE, GET...).


About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors