{"id":20444916,"url":"https://github.com/snapchat/snapml-templates","last_synced_at":"2025-08-17T00:32:11.658Z","repository":{"id":38444471,"uuid":"368323652","full_name":"Snapchat/snapml-templates","owner":"Snapchat","description":null,"archived":false,"fork":false,"pushed_at":"2024-06-17T20:04:15.000Z","size":71955,"stargazers_count":84,"open_issues_count":3,"forks_count":27,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-04-04T21:23:56.024Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Snapchat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-05-17T21:14:47.000Z","updated_at":"2025-01-27T23:31:38.000Z","dependencies_parsed_at":"2024-06-17T22:16:31.751Z","dependency_job_id":null,"html_url":"https://github.com/Snapchat/snapml-templates","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Snapchat/snapml-templates","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snapchat%2Fsnapml-templates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snapchat%2Fsnapml-templates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snapchat%2Fsnapml-templates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snapchat%2Fsnapml-templates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Snapchat","download_url":"https://codeload.github.com/Snapchat/snapml-templates/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snapchat%2Fsnapml-templates/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270791255,"owners_count":24645781,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-16T02:00:11.002Z","response_time":91,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-15T10:10:02.106Z","updated_at":"2025-08-17T00:32:06.635Z","avatar_url":"https://github.com/Snapchat.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# snapml-templates\nThis repository provides training notebooks for Lens Studio templates powered with Snap ML.\nEach notebook allows to train a model which then can be brought into Lens Studio project.\n\n[Lens Studio download page](https://lensstudio.snapchat.com/download/)\n\n[SnapML overview](https://lensstudio.snapchat.com/guides/machine-learning/)\n\n# Templates \n\n## Style Transfer\nAllows you to train Style Transfer model based on provided image. \n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150581229-c4aa60d6-f371-4919-9372-0f421a9476a3.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Style%20Transfer/style_transfer.ipynb)\n- Dataset: [COCO](http://cocodataset.org/#explore) dataset\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/style-transfer)\n\n## Classification\nProvides an example of binary classification \n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150581048-13e05812-04ee-44a8-96a6-2f1446243175.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Classification/eyeglasses_classification.ipynb)\n- Dataset: [CelebA](https://drive.google.com/drive/folders/0B7EVK8r0v71pWEZsZE9oNnFzTm8)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/classification)\n\n## Object Detection \nProvides an example of the car detection  \n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150581045-40e01183-334c-4631-8115-70b4a0b2c7c3.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Object%20Detection/object_detection.ipynb)\n- Dataset: [COCO](http://cocodataset.org/#explore)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/object-detection)\n\n## Custom Segmentation \nProvides an example of pizza segmentation  \n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150581035-bde72638-c804-447d-b9ac-f678bc6f26a1.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Custom%20Segmentation/segmentation_training.ipynb)\n- Dataset: [COCO](http://cocodataset.org/#explore)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/custom-segmentation)\n\n## Keyword Detection \nProvides an example of training a model that classifies spectrogram images generated from audio.\n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150581018-e4395543-8685-4d54-a351-a0eb0813cc27.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Keyword%20Detection/Keyword_Detection.ipynb)\n- Dataset: [SpeechCommands](https://arxiv.org/abs/1804.03209)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/audio/keyword-detection)\n\n## Image-to-Image Translation\nDemonstrates how to train and compress popular image-to-image networks like [CycleGAN](https://junyanz.github.io/CycleGAN/) and [Pix2Pix](https://phillipi.github.io/pix2pix/) so that we could achieve real time performance on mobile devices. \n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/150579553-1b48de31-1fb2-47a7-93fb-7a3dd4369870.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Image-to-Image%20Translation/Image_to_Image_translation_with_GAN_Compression.ipynb)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/style-transfer) (This model is compatible with Style Transfer Template)\n\n## Multi Class Classification with Quantization\nDemonstrates how to train an image classification models with Keras and TFLite model maker and quantize them using TensorFlow\n\n\u003cimg src=\"https://user-images.githubusercontent.com/84346153/164765465-8ec22c64-e134-4cb6-903f-57e5c55b4c71.gif\" width=\"200\"\u003e\n\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Quantization%20With%20TFLite/classification_and_quantization_with_tflite.ipynb)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/multi-class-classification)\n\n## Multi-Object Detection\nDemonstrates how to train a multi-object detection model using custom datasets annotated by ourselves with a step-by-step example on berries detection.\n\n\u003cimg src=\"https://user-images.githubusercontent.com/81824886/201995717-bffac47a-52ed-41c4-8d4e-184ec6d15092.gif\" width=\"200\"\u003e\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Multi-Object%20Detection/Multi-Object%20Detection.ipynb)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/multi-object-detection)\n\n\n## SnapAR Global Lensathon - SnapML Workshop\nEducational walkthrough of how to train your own image classifier from scratch and making it SnapML compatible. This is intended for educational purposes only. Please review relevant dataset licenses prior to usage.\n\n- [Notebook](https://github.com/Snapchat/snapml-templates/blob/9a2b3b6e4aaa93e3a8d39f0322fdcc0a3e4fe622/SnapAR%20Global%20Lensathon%20-%20SnapML%20Workshop/%5BSnap_AR_Lensathon%5D_SnapML_Image_Classification_Tutorial.ipynb)\n\n## Optical Character Recognition\nThrough Snap’s partnership with OpenCV, we are bringing to you a training notebook that allows you to train ML Models that can be later brought into Lens Studio and used to recognize text in the camera view.\n\n\u003cimg src=\"https://github.com/Snapchat/snapml-templates/assets/84346153/980cecdb-24e8-4abd-897e-288ac39517e6.gif\" width=\"200\"\u003e\n\n- [Inference Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Optical%20Character%20Recognition/Optical%20Character%20Recognition%20-%20ONNX%20Inference.ipynb)\n- [Training Notebook](https://github.com/Snapchat/snapml-templates/blob/main/Optical%20Character%20Recognition/Optical%20Character%20Recognition%20-%20OCR%20Training.ipynb) (optional)\n- [Template Guide](https://docs.snap.com/lens-studio/references/templates/ml/optical-character-recognition)\n\n## Real-Time Neural Rendering\nThe template demonstrates how to render 3D assets real-time on device on Snapchat, using 2D images captured with a phone. There are also notebooks with training code to generate any 3D asset, and helpful guides covering how to deploy these models into a Lens.\n\n\u003cimg src=\"https://github.com/Snapchat/snapml-templates/assets/84346153/f66d670a-734d-405e-a541-4cb456f67b9d\" width=\"200\"\u003e\n\nThis is a state-of-the-art model based on a [research paper](https://snap-research.github.io/MobileR2L/) from Snap’s Creative Vision Research team that was accepted into CVPR this year, one of the most important and major computer vision and ML conferences in the world, where we also presented a live demo. This model and template in Lens Studio showcases how Snap’s research becomes an applied project that any developer can use.\n\n- [Inference Notebook](Neural%20Rendering/Realtime%20Neural%20Rendering.ipynb)\n- [Guide](Neural%20Rendering/Advanced%20Neural%20Rendering%20Guide.md)\n- [Lens Studio Project](Neural%20Rendering/Lens%20Studio%20Projects/360)\n\n\n\n## License\nA license file is included with each folder project.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnapchat%2Fsnapml-templates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnapchat%2Fsnapml-templates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnapchat%2Fsnapml-templates/lists"}