--- title: Sidewalk Segmentation with SAM - Shiny Web App emoji: 🌍 colorFrom: green colorTo: indigo sdk: docker pinned: false license: mit --- # CS370 - Project Web App - Aaron Schwarzwaelder This web app is a simple interface for running the sidewalk segmentation model on a user-provided image. It is built using the Shiny framework in Python. For more information on how to train the segmentation model refer to [this](https://github.com/aarons20/cs370-assignments/tree/main/project_1) repository. ## Development Environment Setup To develop the web app locally you can use a virtual environment. Install all required Python packages listed in `requirements.txt`. To run the application locally change to the `app` directory and execute the following command. ```bash shiny run --reload --launch-browser app.py ``` ## Build the Container The project uses a container that contains all required Python packages listed in `requirements.txt`. To ensure a smooth startup of the container, follow the steps. Make sure to execute the commands in the projects directory. ```bash docker build -t project-web-app-image . ``` ## Start the Container ```bash docker run -p 8080:7860 project-web-app-image ``` ## Publish on Hugging Face After the development of the web app, the container can be published on Hugging Face. To automate this process, this repository contains a GitHub Action that automatically publishes the container on Hugging Face. The hosted application can be found on Hugging Face at the following link: [Sidewalk Segmentation with SAM](https://huggingface.co/spaces/UpToDataScience/SidewalkSegmentation_Shiny) ## Project Video [This](https://www.youtube.com/watch?v=e8YOMNLTm0g) video provides short insights into the project. It covers the main features and a demonstration of how the developed application works.