Web Sam for UKHCWebSAM for UKHC is a three part package:WebSAM for UKHC RepositoryWebSAM for UKHC leverages Segment Anything to provide in-browser image segmentations. It consists of a ReactJS frontend, and a FastAPI python backend which contains API functions for saving and loading images, generating segmentation masks, and uploading JSON files with points to replicate results.To create a segmentation, all…
Source code on GitHub.
WebSAM for UKHC is a three part package:
WebSAM for UKHC leverages Segment Anything to provide in-browser image segmentations. It consists of a ReactJS frontend, and a FastAPI python backend which contains API functions for saving and loading images, generating segmentation masks, and uploading JSON files with points to replicate results.
To create a segmentation, all you have to do is upload a file, click, and then when done clicking you can save the image to the database. Additionally, the threshold slider allows you to tweak segmentation around the click points.
There is a tab which only shows up when an image is uploaded and the first point has been placed. The button is Download Results which allows you to download the file, generate and save a mask file, and save a json file with the points used to create the segmentation to the WebSAM Image Database.
Sturdy Waddle is a fork of the template site. It has been modified to have a page which features the WebSAM interface, and a page which shows the files which are stored in the database. Minimal changes have been made from the original template site.
WebSAM Image Database contains code to save images that are downloaded frm WebSAM-for-UKHC, as well as to provide identifying information and thumbnails for the images to be placed in the processed tab of sturdy-waddle.
This is not an interactive site, it is simply a stand-in for a database implementation down the road. For now, it creates and saves files to a folder called datasets.