Skip to content

Example application of using Pytorch with fastapi and AWS App Runner

License

Notifications You must be signed in to change notification settings

nogibjj/pytorch-fastapi-aws-apprunner

Repository files navigation

FastAPI PyTorch Example

Converted from official tutorial

Tasks:

  1. Run the fastapi app: python app.py
  2. Upload an image to classify, say a cat using the swagger docs url: /docs
  3. Deploy to AWS using the free tier and the AWS App Runner service

Notes on Running docker with PyTorch and FastAPI

docker build .

Note this is your container name use: docker image ls to find (replace id with your image id):

docker run -p 127.0.0.1:8080:8080 54a55841624f

fastapi-step1 fastapi-step2 fastapi-step3 fastapi-step4

Verify Swagger Working

Go to /docs url

References

About

Example application of using Pytorch with fastapi and AWS App Runner

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published