GithubHelp home page GithubHelp logo

falco2202 / provision-detect-model Goto Github PK

View Code? Open in Web Editor NEW
6.0 1.0 0.0 6.02 MB

Set up infrastructure ECS cluster for AI Model

License: MIT License

HCL 91.10% Dockerfile 3.12% Python 5.77%
ecs-fargate keypoint-detection terraform gitops fastapi ci-cd github-actions infrastructure-as-code

provision-detect-model's Introduction

ECS Infrastructure for Pose Detection - Infrastructure as Code

Infrastructure

image

  • Note: To reduce complexity and cost, I ran the container in the public subnet. (It is still best practice to keep container in the private subnet).

Folder structure

.
├── detect-model
|   ├── app
|   |      ├── __init__.py
|   |      ├── app.py
|   |      └── yolov8n-pose.py             # Model pose detect image
|   ├── Dockerfile
|   └── requirements.txt          
├── environment
|       ├── development                    # Infrastructure Dev environment
|       |      ├── main.tf
|       |      ├── variables.tf
|       |      ├── terraform.tfvars
|       |      └── ...
|       ├── production                     # Infrastructure Production environment     
|       |      ├── main.tf
|       |      ├── variables.tf
|       |      ├── terraform.tfvars
|       |      └── ...             
├── module
|   ├── acm
|   |    ├── main.tf
|   |    ├── variables.tf
|   |    └── outputs.tf
|   ├── alb
|   ├── ecr
|   ├── ecs
|   ├── networking
|   └── route53                 
├── .gitignore                   
├── LICENSE.md
└── README.md

Usage repository

  1. Clone repository
git clone https://github.com/falco2202/provision-detect-model.git
  1. To add your AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY to Github secret, as well as your preferred REGION in Github variables.
  2. Run job in GitHub action

Load test

  • Note: Application is tested for performance with ECS Fargate(task: 1 vCPU, 2GB Memory) and autoscaling (min: 2, max: 5)

image

-> The server died with the 15 users and 13 requests/second

provision-detect-model's People

Contributors

falco2202 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

provision-detect-model's Issues

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.