Skip to content

nutriomatic/predict-api

Repository files navigation

Predict API

Trigger the predict function from the model and get the API prediction endpoint :

This is a python code, so make sure you have python installed on your system.

Installation and Usage

Docker must be installed on your system.

Building the Docker Image

  1. Clone the repository:
    git clone https://github.com/nutriomatic/predict-api.git
    cd predict-api
  1. Build the Docker image:
   docker build -t predict-api .

Running the Application

  1. Run the Docker container:
   docker run -d -p 8080:8080 --name predict-api predict-api

This will start the application and map port 8080 of the Docker container to port 8080 on your local machine.

  1. Access the application: Open your web browser and navigate to http://localhost:8080

  2. If it shows 'Hello, world!' then you have successfully run the predict api.

  3. The next step is to configure the backend service, you can find it in the backend repository.

Stopping the Application

  1. Stop the Docker container:
   docker stop predict-api
  1. Remove the Docker container:
   docker rm predict-api

Directory Structure

.
├── core
│   ├── main.py
│   └── utils.py
├── models
│   ├── model_grade_predict_dum.h5
│   ├── model_new.h5
│   └── scaler.joblib
├── app.py
├── Dockerfile
├── requirements.txt
└── README.md

Contributions

Contributions are welcome! Please fork the repository and submit a pull request with your improvements or new features.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published