├── .github └── PULL_REQUEST_TEMPLATE.md ├── .gitignore ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── MRE-Developer-Guide.md ├── MRE-Migration.md ├── NOTICE ├── README.md ├── deployment ├── build-and-deploy.sh ├── build-open-source-dist.sh ├── env-init.sh ├── env-role-permissions.json ├── install-python311-cloud9.sh ├── lambda_layer_factory │ ├── Dockerfile │ ├── build-lambda-layer.sh │ └── docker-entrypoint.sh └── uninstall.sh ├── docs ├── README.md ├── assets │ └── images │ │ ├── MRE_Architecture.png │ │ ├── MRE_Logo.png │ │ ├── Postman_Sample.png │ │ ├── devguide-create-events.png │ │ ├── devguide-mre-solutions.png │ │ ├── devguide-plugin-classes.png │ │ ├── devguide-plugin-elements.png │ │ ├── devguide-profile-example.png │ │ ├── devguide-system-diagram.png │ │ └── mre-header-1.png ├── guides │ ├── MRE-Developer-Guide-APIAuth.md │ ├── MRE-Developer-Guide-Events.md │ ├── MRE-Developer-Guide-Export.md │ ├── MRE-Developer-Guide-Extension.md │ ├── MRE-Developer-Guide-Featurer.md │ ├── MRE-Developer-Guide-Labeler.md │ ├── MRE-Developer-Guide-Models.md │ ├── MRE-Developer-Guide-Operations.md │ ├── MRE-Developer-Guide-Optimizer.md │ ├── MRE-Developer-Guide-Plugins.md │ ├── MRE-Developer-Guide-Profiles.md │ ├── MRE-Developer-Guide-Replays.md │ ├── MRE-Developer-Guide-Segmenter.md │ └── MRE-Developer-Guide-Video.md └── source │ ├── api │ ├── controlplane-contentgroup.rst │ ├── controlplane-custompriorities.rst │ ├── controlplane-event.rst │ ├── controlplane-model.rst │ ├── controlplane-plugin.rst │ ├── controlplane-profile.rst │ ├── controlplane-program.rst │ ├── controlplane-replay.rst │ ├── controlplane-system.rst │ ├── controlplane-workflow.rst │ ├── dataplane.rst │ └── gateway.rst │ ├── build_docs.sh │ ├── conf.py │ ├── index.rst │ ├── main.rst │ ├── output │ ├── .buildinfo │ ├── .doctrees │ │ ├── api │ │ │ ├── controlplane-contentgroup.doctree │ │ │ ├── controlplane-custompriorities.doctree │ │ │ ├── controlplane-event.doctree │ │ │ ├── controlplane-model.doctree │ │ │ ├── controlplane-plugin.doctree │ │ │ ├── controlplane-profile.doctree │ │ │ ├── controlplane-program.doctree │ │ │ ├── controlplane-replay.doctree │ │ │ ├── controlplane-system.doctree │ │ │ ├── controlplane-workflow.doctree │ │ │ ├── dataplane.doctree │ │ │ └── gateway.doctree │ │ ├── environment.pickle │ │ ├── index.doctree │ │ └── main.doctree │ ├── _sources │ │ ├── api │ │ │ ├── controlplane-contentgroup.rst.txt │ │ │ ├── controlplane-custompriorities.rst.txt │ │ │ ├── controlplane-event.rst.txt │ │ │ ├── controlplane-model.rst.txt │ │ │ ├── controlplane-plugin.rst.txt │ │ │ ├── controlplane-profile.rst.txt │ │ │ ├── controlplane-program.rst.txt │ │ │ ├── controlplane-replay.rst.txt │ │ │ ├── controlplane-system.rst.txt │ │ │ ├── controlplane-workflow.rst.txt │ │ │ ├── dataplane.rst.txt │ │ │ └── gateway.rst.txt │ │ ├── index.rst.txt │ │ └── main.rst.txt │ ├── _static │ │ ├── asciinema-player.css │ │ ├── asciinema-player.js │ │ ├── aws-sdk-2.826.0.min.js │ │ ├── basic.css │ │ ├── bootstrap-reboot.css │ │ ├── custom-tabs.css │ │ ├── default.css │ │ ├── doctools.js │ │ ├── documentation_options.js │ │ ├── favicon.png │ │ ├── file.png │ │ ├── img │ │ │ ├── MRE_Color.png │ │ │ ├── coding.png │ │ │ ├── maintenance.png │ │ │ ├── programming.png │ │ │ └── speed.svg │ │ ├── language_data.js │ │ ├── minus.png │ │ ├── plus.png │ │ ├── pygments.css │ │ ├── searchtools.js │ │ └── sphinx_highlight.js │ ├── api │ │ ├── controlplane-contentgroup.html │ │ ├── controlplane-custompriorities.html │ │ ├── controlplane-event.html │ │ ├── controlplane-model.html │ │ ├── controlplane-plugin.html │ │ ├── controlplane-profile.html │ │ ├── controlplane-program.html │ │ ├── controlplane-replay.html │ │ ├── controlplane-system.html │ │ ├── controlplane-workflow.html │ │ ├── dataplane.html │ │ └── gateway.html │ ├── genindex.html │ ├── index.html │ ├── main.html │ ├── objects.inv │ ├── search.html │ └── searchindex.js │ ├── requirements.txt │ └── theme │ └── smithy │ ├── globaltoc.html │ ├── landing.html │ ├── layout.html │ ├── static │ ├── asciinema-player.css │ ├── asciinema-player.js │ ├── aws-sdk-2.826.0.min.js │ ├── bootstrap-reboot.css │ ├── custom-tabs.css │ ├── default.css_t │ ├── favicon.png │ └── img │ │ ├── MRE_Color.png │ │ ├── coding.png │ │ ├── maintenance.png │ │ ├── programming.png │ │ └── speed.svg │ └── theme.conf ├── samples ├── LICENSE ├── NOTICE ├── README.md ├── deployment │ └── build-and-deploy.sh └── source │ ├── custom-resource │ ├── handler.py │ └── requirements.txt │ ├── mre-fan-experience-frontend │ ├── amplify.yml │ ├── cdk │ │ ├── app.py │ │ ├── cdk.json │ │ ├── create-env-file.py │ │ ├── init-amplify.py │ │ ├── requirements.txt │ │ └── stacks │ │ │ ├── __init__.py │ │ │ └── mre_fan_experience_frontend_stack.py │ ├── env.template │ ├── package.json │ ├── public │ │ ├── favicon.ico │ │ ├── index.html │ │ └── manifest.json │ └── src │ │ ├── App.css │ │ ├── App.js │ │ ├── Routes.js │ │ ├── assets │ │ ├── aws-logo.svg │ │ ├── fonts │ │ │ ├── amazon-ember-medium-webfont.woff │ │ │ ├── amazon-ember-medium-webfont.woff2 │ │ │ ├── amazon-ember-mediumitalic-webfont.woff │ │ │ ├── amazon-ember-mediumitalic-webfont.woff2 │ │ │ ├── amazonember_bd-webfont.woff │ │ │ ├── amazonember_bd-webfont.woff2 │ │ │ ├── amazonember_bdit-webfont.ttf │ │ │ ├── amazonember_bdit-webfont.woff │ │ │ ├── amazonember_bdit-webfont.woff2 │ │ │ ├── amazonember_he-webfont.woff │ │ │ ├── amazonember_he-webfont.woff2 │ │ │ ├── amazonember_heit-webfont.woff │ │ │ ├── amazonember_heit-webfont.woff2 │ │ │ ├── amazonember_lt-webfont.ttf │ │ │ ├── amazonember_lt-webfont.woff │ │ │ ├── amazonember_lt-webfont.woff2 │ │ │ ├── amazonember_ltit-webfont.woff │ │ │ ├── amazonember_ltit-webfont.woff2 │ │ │ ├── amazonember_rg-webfont.woff │ │ │ ├── amazonember_rg-webfont.woff2 │ │ │ ├── amazonember_rgit-webfont.woff │ │ │ ├── amazonember_rgit-webfont.woff2 │ │ │ ├── amazonember_th-webfont.ttf │ │ │ ├── amazonember_th-webfont.woff │ │ │ ├── amazonember_th-webfont.woff2 │ │ │ ├── amazonember_thit-webfont.woff │ │ │ ├── amazonember_thit-webfont.woff2 │ │ │ └── fonts.css │ │ ├── football.svg │ │ ├── football_gradiant.svg │ │ ├── golf.svg │ │ ├── golf_gradiant.svg │ │ ├── soccer.svg │ │ ├── soccer_background.jpg │ │ ├── soccer_gradiant.svg │ │ ├── swimming.svg │ │ ├── swimming_gradiant.svg │ │ ├── tennis.svg │ │ ├── tennis_background.jpg │ │ └── tennis_gradiant.svg │ │ ├── common │ │ ├── APIHandler │ │ │ └── APIHandler.js │ │ ├── Constants.js │ │ ├── Copyright.js │ │ ├── routes │ │ │ ├── AuthenticatedRoute.js │ │ │ └── UnauthenticatedRoute.js │ │ └── utils │ │ │ ├── utils.js │ │ │ └── withRouter.js │ │ ├── components │ │ ├── CollapsedMenuOverlay │ │ │ └── CollapsedMenuOverlay.js │ │ ├── ExpandedMenuOverlay │ │ │ └── ExpandedMenuOverlay.js │ │ ├── Header │ │ │ └── Header.js │ │ ├── Layouts │ │ │ └── DemoContainer.js │ │ ├── SegmentButton │ │ │ └── SegmentButton.js │ │ ├── Streamer │ │ │ └── Streamer.js │ │ └── StreamerControls │ │ │ └── StreamerControls.js │ │ ├── config.js │ │ ├── containers │ │ ├── Events │ │ │ ├── EventItem.js │ │ │ ├── EventList.js │ │ │ └── Events.js │ │ ├── HighlightViewer │ │ │ └── HighlightViewer.js │ │ ├── Home │ │ │ └── Home.js │ │ ├── Login │ │ │ ├── ChangePassword.js │ │ │ ├── Login.js │ │ │ └── LoginForm.js │ │ └── NotFound │ │ │ └── NotFound.js │ │ ├── contexts │ │ └── SessionContext.js │ │ ├── index.css │ │ ├── index.js │ │ ├── registerServiceWorker.js │ │ └── theme │ │ └── defaultTheme.js │ ├── mre-model-samples │ └── Models │ │ ├── AudioEmbeddingClassificationModel │ │ ├── AudioEmbeddingClassificationModel.ipynb │ │ ├── README.md │ │ └── config.json │ │ ├── AudioEmbeddingModel │ │ ├── AudioEmbeddingModel.ipynb │ │ ├── DockerImage │ │ │ ├── Dockerfile │ │ │ ├── config.properties │ │ │ └── mms-entrypoint.py │ │ ├── README.md │ │ ├── build_your_custom_image.sh │ │ ├── config.json │ │ ├── inference_src │ │ │ └── entrypoint.py │ │ └── model.tar.gz │ │ ├── AudioSpectrumClassificationModel │ │ ├── AudioSpectrumClassification.ipynb │ │ ├── README.md │ │ └── config.json │ │ ├── PoseClassificationModel │ │ ├── PoseClassificationModel.ipynb │ │ ├── README.md │ │ └── config.json │ │ ├── PoseKeypointsExtractionModel │ │ ├── PoseKeypointsExtractionModel.ipynb │ │ ├── README.md │ │ ├── config.json │ │ ├── images │ │ │ └── soccer.png │ │ └── inference_src │ │ │ └── entrypoint.py │ │ ├── README.md │ │ ├── SceneClassificationModel │ │ ├── README.md │ │ ├── RekognitionCLTraining.ipynb │ │ ├── config.json │ │ └── output.manifest │ │ ├── ScoreBoxDetectionModel │ │ ├── README.md │ │ ├── RekognitionCLTraining.ipynb │ │ ├── config.json │ │ └── output.manifest │ │ └── template_model_config.json │ ├── mre-plugin-samples │ ├── Plugins │ │ ├── DetectAudioPeaks │ │ │ ├── DetectAudioPeaks.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectAudioScene │ │ │ ├── DetectAudioScene.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectAudioSilence │ │ │ ├── DetectAudioSilence.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── audio_detect.py │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectCameraScene │ │ │ ├── DetectCameraScene.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectExternalData │ │ │ ├── DetectExternalData.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── DetectFaces │ │ │ ├── DetectFaces.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectPassThrough1 │ │ │ ├── DetectPassThrough1.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── DetectPassThrough100 │ │ │ ├── DetectPassThrough100.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── DetectPose │ │ │ ├── DetectPose.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectPoseKeypoints │ │ │ ├── DetectPoseKeypoints.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectSceneChange │ │ │ ├── DetectSceneChange.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ ├── requirements.txt │ │ │ └── scene_detect.py │ │ ├── DetectSentiment │ │ │ ├── DetectSentiment.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── DetectShotsByRekognitionVideo │ │ │ ├── DetectShotsByRekognitionVideo.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectSoccerScene │ │ │ ├── DetectSoccerScene.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectSpeech │ │ │ ├── DetectSpeech.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectTennisScoreBoxData │ │ │ ├── DetectTennisScoreBoxData.py │ │ │ ├── Dockerfile │ │ │ ├── README.md │ │ │ ├── config.json │ │ │ └── requirements.txt │ │ ├── DetectTennisVolley │ │ │ ├── DetectTennisVolley.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── Dockerfile.template │ │ ├── LabelBasic │ │ │ ├── LabelBasic.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── LabelPassThrough │ │ │ ├── LabelPassThrough.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── LabelTennisAceDoubleFault │ │ │ ├── LabelTennisAceDoubleFault.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── LabelTennisScore │ │ │ ├── LabelTennisScore.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── OptimizePassThrough │ │ │ ├── OptimizePassThrough.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── OptimizeSegment │ │ │ ├── OptimizeSegment.py │ │ │ ├── README.md │ │ │ └── config.json │ │ ├── README.md │ │ ├── SegmentByCommercials │ │ │ ├── README.md │ │ │ ├── SegmentByCommercials.py │ │ │ └── config.json │ │ ├── SegmentByKeyMoment │ │ │ ├── README.md │ │ │ ├── SegmentByKeyMoment.py │ │ │ └── config.json │ │ ├── SegmentBySceneChange │ │ │ ├── README.md │ │ │ ├── SegmentBySceneChange.py │ │ │ └── config.json │ │ ├── SegmentBySceneChangeWithOffset │ │ │ ├── README.md │ │ │ ├── SegmentBySceneChangeWithOffset.py │ │ │ └── config.json │ │ ├── SegmentByShot │ │ │ ├── README.md │ │ │ ├── SegmentByShot.py │ │ │ └── config.json │ │ ├── SegmentFromTranscription │ │ │ ├── README.md │ │ │ ├── SegmentFromTranscription.py │ │ │ └── config.json │ │ ├── SegmentPassThrough │ │ │ ├── README.md │ │ │ ├── SegmentPassThrough.py │ │ │ └── config.json │ │ ├── SegmentPassThrough100 │ │ │ ├── README.md │ │ │ ├── SegmentPassThrough100.py │ │ │ └── config.json │ │ └── template_plugin_config.json.template │ └── cdk │ │ ├── app.py │ │ ├── cdk.context.json │ │ ├── cdk.json │ │ ├── requirements.txt │ │ └── stacks │ │ ├── __init__.py │ │ └── mre_plugins_stack.py │ ├── mre-profile-samples │ ├── audit-pass-through-plugins │ │ └── config.json │ ├── basic-soccer │ │ └── config.json │ ├── basic-soccer2 │ │ └── config.json │ ├── basic-tennis │ │ └── config.json │ ├── basic-tennis2 │ │ └── config.json │ └── template_profile_config.json.template │ └── mre-video-ingestion-samples │ └── HLS_Harvester │ ├── harvester_config_template.py │ ├── infrastructure │ ├── app.py │ ├── cdk.json │ ├── requirements.txt │ └── stacks │ │ ├── __init__.py │ │ └── chaliceapp.py │ ├── requirements.txt │ └── runtime │ ├── .chalice │ └── config.json │ ├── app.py │ ├── chalicelib │ ├── __init__.py │ └── user_data.txt │ └── requirements.txt ├── source ├── api │ ├── controlplane │ │ ├── contentgroup │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ └── requirements.txt │ │ ├── custompriorities │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ └── apischema │ │ │ │ │ ├── create_custom_priorities_engine.json │ │ │ │ │ ├── update_custom_priorities_engine.json │ │ │ │ │ └── update_status.json │ │ │ │ └── requirements.txt │ │ ├── event │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── EventScheduler.py │ │ │ │ ├── Schedule.py │ │ │ │ ├── __init__.py │ │ │ │ ├── apischema │ │ │ │ │ ├── create_event.json │ │ │ │ │ └── update_event.json │ │ │ │ └── helpers.py │ │ │ │ └── requirements.txt │ │ ├── model │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ └── apischema │ │ │ │ │ ├── register_model.json │ │ │ │ │ └── update_status.json │ │ │ │ └── requirements.txt │ │ ├── plugin │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ └── apischema │ │ │ │ │ ├── register_plugin.json │ │ │ │ │ └── update_status.json │ │ │ │ └── requirements.txt │ │ ├── profile │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── lambda │ │ │ │ │ ├── MultiChunkHelper │ │ │ │ │ │ └── lambda_function.py │ │ │ │ │ ├── PluginOutputHandler │ │ │ │ │ │ └── lambda_function.py │ │ │ │ │ ├── ProbeVideo │ │ │ │ │ │ └── lambda_function.py │ │ │ │ │ └── WorkflowErrorHandler │ │ │ │ │ │ └── lambda_function.py │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ ├── apischema │ │ │ │ │ ├── create_profile.json │ │ │ │ │ ├── update_profile.json │ │ │ │ │ └── update_status.json │ │ │ │ ├── profile_creation_helper.py │ │ │ │ └── profile_state_dfn_helper.py │ │ │ │ └── requirements.txt │ │ ├── program │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ └── requirements.txt │ │ ├── replay │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ └── apischema │ │ │ │ │ └── add_replay.json │ │ │ │ └── requirements.txt │ │ ├── system │ │ │ ├── infrastructure │ │ │ │ ├── app.py │ │ │ │ ├── cdk.json │ │ │ │ ├── requirements.txt │ │ │ │ └── stacks │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ │ ├── .chalice │ │ │ │ └── config.json │ │ │ │ ├── app.py │ │ │ │ ├── chalicelib │ │ │ │ ├── __init__.py │ │ │ │ └── apischema │ │ │ │ │ └── put_system_configuration.json │ │ │ │ └── requirements.txt │ │ └── workflow │ │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── __init__.py │ │ │ │ └── chaliceapp.py │ │ │ ├── requirements.txt │ │ │ └── runtime │ │ │ ├── .chalice │ │ │ └── config.json │ │ │ ├── app.py │ │ │ ├── chalicelib │ │ │ └── __init__.py │ │ │ └── requirements.txt │ └── dataplane │ │ ├── infrastructure │ │ ├── app.py │ │ ├── cdk.json │ │ ├── lambda │ │ │ ├── DynamoGSIHandler │ │ │ │ └── lambda_function.py │ │ │ ├── DynamoIsCompleteHandler │ │ │ │ └── lambda_function.py │ │ │ └── EventDeletionHandler │ │ │ │ └── lambda_function.py │ │ ├── requirements.txt │ │ └── stacks │ │ │ ├── __init__.py │ │ │ └── chaliceapp.py │ │ ├── requirements.txt │ │ └── runtime │ │ ├── .chalice │ │ └── config.json │ │ ├── app.py │ │ ├── chalicelib │ │ ├── __init__.py │ │ ├── apischema │ │ │ ├── get_chunks_for_segment.json │ │ │ ├── get_dependent_plugins_output.json │ │ │ ├── get_segment_state.json │ │ │ ├── get_segment_state_for_labeling.json │ │ │ ├── get_segment_state_for_optimization.json │ │ │ ├── get_segments_for_clip_generation.json │ │ │ ├── store_chunk_metadata.json │ │ │ ├── store_clip_preview_feedback.json │ │ │ ├── store_clip_result.json │ │ │ ├── store_frame.json │ │ │ └── store_plugin_result.json │ │ ├── common.py │ │ ├── metadata.py │ │ ├── plugin.py │ │ ├── replay.py │ │ ├── segment.py │ │ ├── segment_helper.py │ │ └── workflow.py │ │ ├── requirements.txt │ │ └── vendor │ │ ├── _pyrsistent_version.py │ │ ├── pyrsistent-0.17.3.dist-info │ │ ├── LICENCE.mit │ │ ├── METADATA │ │ ├── RECORD │ │ ├── WHEEL │ │ └── top_level.txt │ │ └── pyrsistent │ │ ├── __init__.py │ │ ├── __init__.pyi │ │ ├── _checked_types.py │ │ ├── _field_common.py │ │ ├── _helpers.py │ │ ├── _immutable.py │ │ ├── _pbag.py │ │ ├── _pclass.py │ │ ├── _pdeque.py │ │ ├── _plist.py │ │ ├── _pmap.py │ │ ├── _precord.py │ │ ├── _pset.py │ │ ├── _pvector.py │ │ ├── _toolz.py │ │ ├── _transformations.py │ │ ├── py.typed │ │ ├── typing.py │ │ └── typing.pyi ├── backend │ ├── caching │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── __init__.py │ │ │ │ └── chaliceapp.py │ │ ├── requirements.txt │ │ └── runtime │ │ │ ├── lambda │ │ │ └── SegmentCaching │ │ │ │ └── mre-segment-caching.py │ │ │ └── requirements.txt │ ├── clipgeneration │ │ ├── Readme.md │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── ClipGenStack.py │ │ │ │ └── __init__.py │ │ ├── requirements.txt │ │ └── runtime │ │ │ ├── lambda │ │ │ ├── EventClipGenerator │ │ │ │ ├── job_settings_hls.json │ │ │ │ ├── job_settings_mp4.json │ │ │ │ └── mre-event-clip-generator.py │ │ │ ├── EventEdlGenerator │ │ │ │ └── mre_event_edl_gen.py │ │ │ └── EventHlsManifestGenerator │ │ │ │ └── event_hls_manifest_gen.py │ │ │ └── requirements.txt │ ├── data_export │ │ ├── Readme.md │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── DataExporter.py │ │ │ │ └── __init__.py │ │ ├── requirements.txt │ │ └── runtime │ │ │ └── lambda │ │ │ ├── mre_data_exporter.py │ │ │ └── shared │ │ │ ├── MreEventDataExporter.py │ │ │ ├── MreReplayDataExporter.py │ │ │ └── __init__.py │ ├── event-life-cycle │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── __init__.py │ │ │ │ └── chaliceapp.py │ │ ├── requirements.txt │ │ └── runtime │ │ │ └── lambda │ │ │ ├── ChannelStarter.py │ │ │ ├── ChannelStopper.py │ │ │ ├── EventCompletion.py │ │ │ ├── ScheduleCleanupCron.py │ │ │ ├── SchedulePurger.py │ │ │ └── requirements.txt │ ├── replay │ │ ├── PutTransitions.py │ │ ├── infrastructure │ │ │ ├── app.py │ │ │ ├── cdk.json │ │ │ ├── requirements.txt │ │ │ └── stacks │ │ │ │ ├── ReplayStack.py │ │ │ │ └── __init__.py │ │ ├── requirements.txt │ │ └── runtime │ │ │ ├── replay_lambda.py │ │ │ └── shared │ │ │ ├── CacheDiscovery.py │ │ │ ├── CacheSyncManager.py │ │ │ ├── CustomPrioritiesProcessor.py │ │ │ ├── GetReplayResults.py │ │ │ ├── HlsGenerator.py │ │ │ ├── Mp4Generator.py │ │ │ ├── Mp4JobInitializer.py │ │ │ ├── ReplayEngine.py │ │ │ ├── ReplayFeatureProcessor.py │ │ │ ├── __init__.py │ │ │ ├── job_settings_hls.json │ │ │ └── job_settings_mp4.json │ └── workflow_trigger │ │ ├── infrastructure │ │ ├── app.py │ │ ├── cdk.json │ │ ├── requirements.txt │ │ └── stacks │ │ │ ├── __init__.py │ │ │ └── chaliceapp.py │ │ ├── requirements.txt │ │ └── runtime │ │ └── lambda │ │ └── lambda_function.py ├── frontend │ ├── amplify.yml │ ├── cdk │ │ ├── app.py │ │ ├── cdk.json │ │ ├── create-env-file.py │ │ ├── init-amplify.py │ │ ├── requirements.txt │ │ └── stacks │ │ │ ├── __init__.py │ │ │ └── mre_frontend_stack.py │ ├── env.template │ ├── package.json │ ├── public │ │ ├── favicon.ico │ │ ├── index.html │ │ └── manifest.json │ └── src │ │ ├── App.css │ │ ├── App.js │ │ ├── Routes.js │ │ ├── assets │ │ ├── TransitionsImg │ │ │ └── BlackFadeInFadeOut.png │ │ ├── company-logo.svg │ │ ├── fonts │ │ │ ├── amazon-ember-medium-webfont.woff │ │ │ ├── amazon-ember-medium-webfont.woff2 │ │ │ ├── amazon-ember-mediumitalic-webfont.woff │ │ │ ├── amazon-ember-mediumitalic-webfont.woff2 │ │ │ ├── amazonember_bd-webfont.woff │ │ │ ├── amazonember_bd-webfont.woff2 │ │ │ ├── amazonember_bdit-webfont.ttf │ │ │ ├── amazonember_bdit-webfont.woff │ │ │ ├── amazonember_bdit-webfont.woff2 │ │ │ ├── amazonember_he-webfont.woff │ │ │ ├── amazonember_he-webfont.woff2 │ │ │ ├── amazonember_heit-webfont.woff │ │ │ ├── amazonember_heit-webfont.woff2 │ │ │ ├── amazonember_lt-webfont.ttf │ │ │ ├── amazonember_lt-webfont.woff │ │ │ ├── amazonember_lt-webfont.woff2 │ │ │ ├── amazonember_ltit-webfont.woff │ │ │ ├── amazonember_ltit-webfont.woff2 │ │ │ ├── amazonember_rg-webfont.woff │ │ │ ├── amazonember_rg-webfont.woff2 │ │ │ ├── amazonember_rgit-webfont.woff │ │ │ ├── amazonember_rgit-webfont.woff2 │ │ │ ├── amazonember_th-webfont.ttf │ │ │ ├── amazonember_th-webfont.woff │ │ │ ├── amazonember_th-webfont.woff2 │ │ │ ├── amazonember_thit-webfont.woff │ │ │ ├── amazonember_thit-webfont.woff2 │ │ │ └── fonts.css │ │ ├── home_image.svg │ │ ├── light-spd-logo.svg │ │ └── videos │ │ │ └── FadeInOutSample.mp4 │ │ ├── common │ │ ├── APIHandler │ │ │ └── APIHandler.js │ │ ├── Constants.js │ │ ├── Copyright.js │ │ ├── DateTimePicker.css │ │ ├── routes │ │ │ ├── AuthenticatedRoute.js │ │ │ └── UnauthenticatedRoute.js │ │ └── utils │ │ │ ├── utils.js │ │ │ └── withRouter.js │ │ ├── components │ │ ├── ClipPreviewFeedback │ │ │ ├── ClipPlaceholder.js │ │ │ ├── ClipPlayer.js │ │ │ ├── ClipPreviewModal.js │ │ │ ├── FeatureBarChart.js │ │ │ ├── RangeBarChart.js │ │ │ ├── RangeColorPallete.js │ │ │ └── RangeTable.js │ │ ├── ContentGroup │ │ │ ├── ContentGroupCreateModal.js │ │ │ └── ContentGroupDropdown.js │ │ ├── Event │ │ │ ├── AllEventsDropDown.js │ │ │ ├── EventDropdown.js │ │ │ └── ThumbnailCard.js │ │ ├── Footer │ │ │ └── Footer.js │ │ ├── Form │ │ │ ├── Components │ │ │ │ ├── FormMultiSelectWithChips.js │ │ │ │ └── FormSelect.js │ │ │ ├── FormHandler.js │ │ │ └── FormRenderer.js │ │ ├── Header │ │ │ └── Header.js │ │ ├── KeyValueForm │ │ │ ├── KeyValueRow.js │ │ │ └── KeysValuesForm.js │ │ ├── Layouts │ │ │ └── DemoContainer.js │ │ ├── ListRenderer │ │ │ ├── ConfirmDeleteDialog.js │ │ │ ├── EventTracksDialog.js │ │ │ ├── ListRenderer.js │ │ │ └── RowRenderer.js │ │ ├── MultiSelectWithChips │ │ │ ├── CustomChip │ │ │ │ ├── CustomChip.js │ │ │ │ └── CustomChipMenu.js │ │ │ └── MultiSelectWithChips.js │ │ ├── OutputAttributeForm │ │ │ ├── OutputAttributeRow.js │ │ │ └── OutputAttributesForm.js │ │ ├── PluginClassDropdown │ │ │ └── PluginClassDropdown.js │ │ ├── Programs │ │ │ ├── ProgramCreateModal.js │ │ │ └── ProgramDropdown.js │ │ ├── Replay │ │ │ ├── ReplayPriorityList.js │ │ │ ├── ReplayViewDialog.js │ │ │ ├── TransitionsDropdown.js │ │ │ └── common.js │ │ ├── Sidebar │ │ │ └── Sidebar.js │ │ └── SummaryView │ │ │ └── SummaryView.js │ │ ├── config.js │ │ ├── containers │ │ ├── Event │ │ │ ├── ClipPreview.js │ │ │ ├── Components │ │ │ │ ├── EventFilters.js │ │ │ │ └── TimeFilter.js │ │ │ ├── EventCreate.js │ │ │ ├── EventList.js │ │ │ ├── EventStatsCard.js │ │ │ └── EventView.js │ │ ├── Home │ │ │ └── Home.js │ │ ├── Login │ │ │ ├── ChangePassword.js │ │ │ ├── Login.js │ │ │ └── LoginForm.js │ │ ├── Model │ │ │ ├── ModelCreate.js │ │ │ └── ModelList.js │ │ ├── NotFound │ │ │ └── NotFound.js │ │ ├── Plugin │ │ │ ├── PluginCreate.js │ │ │ ├── PluginList.js │ │ │ └── PluginViewDialog.js │ │ ├── Profile │ │ │ ├── Forms │ │ │ │ ├── ConfigurationModal.js │ │ │ │ ├── ProfilePluginsForm.js │ │ │ │ └── ProfilePluginsFormWrapper.js │ │ │ ├── ProfileCreate.js │ │ │ ├── ProfileList.js │ │ │ └── ProfileViewDialog.js │ │ └── Replay │ │ │ ├── HlsViewer.js │ │ │ ├── PluginPriorityItem.js │ │ │ ├── ReplayCreate.js │ │ │ ├── ReplayList.js │ │ │ └── TransitionClipPreview.js │ │ ├── contexts │ │ └── SessionContext.js │ │ ├── index.css │ │ ├── index.js │ │ ├── registerServiceWorker.js │ │ └── theme │ │ └── defaultTheme.js ├── gateway │ ├── infrastructure │ │ ├── app.py │ │ ├── cdk.json │ │ ├── requirements.txt │ │ └── stacks │ │ │ ├── __init__.py │ │ │ └── chaliceapp.py │ ├── requirements.txt │ └── runtime │ │ ├── .chalice │ │ └── config.json │ │ ├── app.py │ │ └── requirements.txt ├── layers │ ├── MediaReplayEnginePluginHelper │ │ └── MediaReplayEnginePluginHelper.zip │ ├── MediaReplayEngineWorkflowHelper │ │ └── MediaReplayEngineWorkflowHelper.zip │ ├── ffmpeg │ │ └── .gitkeep │ ├── ffprobe │ │ └── .gitkeep │ └── timecode │ │ └── .gitkeep ├── lib │ ├── MediaReplayEnginePluginHelper │ │ ├── MediaReplayEnginePluginHelper │ │ │ └── __init__.py │ │ ├── README.md │ │ └── setup.py │ └── MediaReplayEngineWorkflowHelper │ │ ├── MediaReplayEngineWorkflowHelper │ │ └── __init__.py │ │ ├── README.md │ │ └── setup.py └── shared │ ├── infrastructure │ ├── app.py │ ├── cdk.json │ ├── helpers │ │ ├── __init__.py │ │ ├── common.py │ │ └── constants.py │ ├── requirements.txt │ └── stacks │ │ ├── __init__.py │ │ └── sharedResources.py │ └── requirements.txt └── tests ├── .dockerignore ├── .gitignore ├── Infrastructure ├── app.py ├── cdk.json ├── lambdas │ └── event_recorder.py ├── medialive_construct.py ├── sample_video │ └── MRE-Sample.mp4 └── stack.py ├── README.md ├── __init__.py ├── core ├── Events │ ├── channel.py │ ├── common.py │ ├── config │ │ ├── DetectPassThrough100.json │ │ ├── EventPassThrough.json │ │ ├── LabelPassthrough.json │ │ ├── OptimizePassThrough.json │ │ ├── PassThroughProfile.json │ │ └── SegmentPassThrough100.json │ ├── event_byob_test.py │ ├── event_media_live_test.py │ ├── fixtures │ │ ├── event_dependency_data_fixture.py │ │ ├── event_dependency_data_fixture_without_optimizer.py │ │ └── media_channel_fixture.py │ └── models │ │ └── event_config.py ├── Models │ ├── config │ │ ├── invalid_end_point.json │ │ ├── invalid_plugin_class.json │ │ ├── no_end_point.json │ │ └── valid_end_point.json │ └── models_test.py ├── Plugins │ ├── config │ │ ├── DetectPassThrough100.json │ │ ├── LabelPassthrough.json │ │ ├── OptimizePassThrough.json │ │ └── SegmentPassThrough100.json │ └── plugin_test.py └── Profiles │ ├── config │ ├── DetectPassThrough100.json │ ├── LabelPassthrough.json │ ├── OptimizePassThrough.json │ ├── PassThroughProfile.json │ └── SegmentPassThrough100.json │ └── profiles_test.py ├── deploy.sh ├── pytest.ini ├── requirements.txt ├── test-suite-entry.sh └── utils ├── __init__.py ├── api_client.py └── config_mgr.py /.github/PULL_REQUEST_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | *Issue #, if available:* 2 | 3 | *Description of changes:* 4 | 5 | By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice. -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | ## Code of Conduct 2 | This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). 3 | For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact 4 | opensource-codeofconduct@amazon.com with any additional questions or comments. 5 | -------------------------------------------------------------------------------- /docs/README.md: -------------------------------------------------------------------------------- 1 | # Generate MRE API Documentation 2 | 3 | PURPOSE: 4 | 5 | Uses Sphinx with autodoc and chalicedoc plugins to generate pretty HTML 6 | documentation from docstrings in source/**/app.py. Output docs will be saved to docs/source/output/. 7 | 8 | ### PRELIMINARY: 9 | python3 must be installed. 10 | 11 | ### USAGE: 12 | Within the **source** folder, run 13 | 14 | ``` 15 | ./build_docs.sh 16 | ``` 17 | 18 | Finally, open output/index.html -------------------------------------------------------------------------------- /docs/assets/images/MRE_Architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/MRE_Architecture.png -------------------------------------------------------------------------------- /docs/assets/images/MRE_Logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/MRE_Logo.png -------------------------------------------------------------------------------- /docs/assets/images/Postman_Sample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/Postman_Sample.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-create-events.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-create-events.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-mre-solutions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-mre-solutions.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-plugin-classes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-plugin-classes.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-plugin-elements.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-plugin-elements.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-profile-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-profile-example.png -------------------------------------------------------------------------------- /docs/assets/images/devguide-system-diagram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/devguide-system-diagram.png -------------------------------------------------------------------------------- /docs/assets/images/mre-header-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/assets/images/mre-header-1.png -------------------------------------------------------------------------------- /docs/guides/MRE-Developer-Guide-Models.md: -------------------------------------------------------------------------------- 1 | [![Header](../assets/images/mre-header-1.png)](../../MRE-Developer-Guide.md) 2 | 3 | # Developers Guide - Incorporating Machine Learning Models 4 | 5 | MRE makes use of machine learning model endpoints that you design and implement separately. No specific service is required, but successful POC have been completed using AWS services such as: 6 | 7 | - Amazon Rekognition Custom Labels 8 | - Amazon SageMaker 9 | 10 | Any ML endpoint that is accessible by the plugin Lambda function will work. 11 | 12 | Models are registered with MRE to keep associations with Plugins clear for others who may be configuring profiles. 13 | 14 | ## Registering a plugin with MRE 15 | 16 | Models you want to use with MRE should be registered using the **model** API described here: 17 | 18 | [POST /model](https://htmlpreview.github.io/?https://github.com/awslabs/aws-media-replay-engine/blob/main/docs/source/output/api/controlplane-model.html#register-model) 19 | 20 | While model endpoints could be specified within the plugin lambda code explicitly, this model registry helps with A/B comparisons as needs change. 21 | -------------------------------------------------------------------------------- /docs/source/api/controlplane-contentgroup.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/contentgroup/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-custompriorities.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/custompriorities/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-event.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/event/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-model.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/model/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-plugin.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/plugin/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-profile.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/profile/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-program.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/program/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-replay.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/replay/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-system.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/system/runtime -------------------------------------------------------------------------------- /docs/source/api/controlplane-workflow.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/workflow/runtime -------------------------------------------------------------------------------- /docs/source/api/dataplane.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/dataplane/runtime -------------------------------------------------------------------------------- /docs/source/api/gateway.rst: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/gateway/runtime -------------------------------------------------------------------------------- /docs/source/index.rst: -------------------------------------------------------------------------------- 1 | .. Media Replay Engine documentation master file, created by 2 | sphinx-quickstart. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | Documentation 7 | ================================================= 8 | 9 | API Reference 10 | ------------- 11 | 12 | **Gateway API** 13 | 14 | .. toctree:: 15 | :maxdepth: 1 16 | 17 | Gateway 18 | 19 | 20 | **Dataplane API** 21 | 22 | .. toctree:: 23 | :maxdepth: 1 24 | 25 | Dataplane 26 | 27 | 28 | 29 | **Controlplane API** 30 | 31 | .. toctree:: 32 | :maxdepth: 1 33 | 34 | 35 | ContentGroup 36 | Event 37 | Model 38 | Plugin 39 | Profile 40 | Program 41 | Replay 42 | System 43 | Workflow 44 | CustomPriorities 45 | 46 | -------------------------------------------------------------------------------- /docs/source/main.rst: -------------------------------------------------------------------------------- 1 | :orphan: 2 | 3 | .. include:: ./index.rst -------------------------------------------------------------------------------- /docs/source/output/.buildinfo: -------------------------------------------------------------------------------- 1 | # Sphinx build info version 1 2 | # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. 3 | config: d7c323b08374f9f99bafeec04e35e349 4 | tags: 645f666f9bcd5a90fca523b33c5a78b7 5 | -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-contentgroup.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-contentgroup.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-custompriorities.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-custompriorities.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-event.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-event.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-model.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-model.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-plugin.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-plugin.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-profile.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-profile.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-program.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-program.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-replay.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-replay.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-system.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-system.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/controlplane-workflow.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/controlplane-workflow.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/dataplane.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/dataplane.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/api/gateway.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/api/gateway.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/environment.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/environment.pickle -------------------------------------------------------------------------------- /docs/source/output/.doctrees/index.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/index.doctree -------------------------------------------------------------------------------- /docs/source/output/.doctrees/main.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/.doctrees/main.doctree -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-contentgroup.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/contentgroup/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-custompriorities.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/custompriorities/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-event.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/event/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-model.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/model/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-plugin.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/plugin/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-profile.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/profile/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-program.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/program/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-replay.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/replay/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-system.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/system/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/controlplane-workflow.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/controlplane/workflow/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/dataplane.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/api/dataplane/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/api/gateway.rst.txt: -------------------------------------------------------------------------------- 1 | .. chalice:project:: ../../source/gateway/runtime -------------------------------------------------------------------------------- /docs/source/output/_sources/index.rst.txt: -------------------------------------------------------------------------------- 1 | .. Media Replay Engine documentation master file, created by 2 | sphinx-quickstart. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | Documentation 7 | ================================================= 8 | 9 | API Reference 10 | ------------- 11 | 12 | **Gateway API** 13 | 14 | .. toctree:: 15 | :maxdepth: 1 16 | 17 | Gateway 18 | 19 | 20 | **Dataplane API** 21 | 22 | .. toctree:: 23 | :maxdepth: 1 24 | 25 | Dataplane 26 | 27 | 28 | 29 | **Controlplane API** 30 | 31 | .. toctree:: 32 | :maxdepth: 1 33 | 34 | 35 | ContentGroup 36 | Event 37 | Model 38 | Plugin 39 | Profile 40 | Program 41 | Replay 42 | System 43 | Workflow 44 | CustomPriorities 45 | 46 | -------------------------------------------------------------------------------- /docs/source/output/_sources/main.rst.txt: -------------------------------------------------------------------------------- 1 | :orphan: 2 | 3 | .. include:: ./index.rst -------------------------------------------------------------------------------- /docs/source/output/_static/custom-tabs.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Add overrides to how tabs are styled to make them less visually 3 | * obstrusive. Note, however, that this might need to be looked at in 4 | * the future if we ever want to use non-code-tabs. 5 | */ 6 | 7 | /* No need for margin below code samples when in a tab. */ 8 | .code-tab pre { 9 | margin-bottom: 0; 10 | } 11 | 12 | .sphinx-tabs { 13 | margin-top: 1rem; 14 | } 15 | 16 | /* Code tabs should encompass the entire tab. */ 17 | .code-tab.tab { 18 | padding: 0 !important; 19 | } 20 | 21 | .ui.tabular.menu { 22 | border: none; 23 | } 24 | 25 | .ui.tabular.menu .item { 26 | font-size: 0.8em; 27 | font-family: "SFMono-Regular",Consolas,"Liberation Mono",Menlo,Courier,monospace; 28 | text-transform: lowercase; 29 | border: none !important; 30 | } 31 | 32 | .ui.attached.segment.code-tab { 33 | border: none !important; 34 | } 35 | 36 | /* Remove code tab headings and use the same color as code backgrounds */ 37 | .ui.tabular.menu .active.item { 38 | border: none !important; 39 | background-color: inherit; 40 | text-decoration: underline; 41 | font-weight: normal; 42 | } 43 | -------------------------------------------------------------------------------- /docs/source/output/_static/documentation_options.js: -------------------------------------------------------------------------------- 1 | var DOCUMENTATION_OPTIONS = { 2 | URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), 3 | VERSION: '', 4 | LANGUAGE: 'en', 5 | COLLAPSE_INDEX: false, 6 | BUILDER: 'html', 7 | FILE_SUFFIX: '.html', 8 | LINK_SUFFIX: '.html', 9 | HAS_SOURCE: true, 10 | SOURCELINK_SUFFIX: '.txt', 11 | NAVIGATION_WITH_KEYS: false, 12 | SHOW_SEARCH_SUMMARY: true, 13 | ENABLE_SEARCH_SHORTCUTS: true, 14 | }; -------------------------------------------------------------------------------- /docs/source/output/_static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/favicon.png -------------------------------------------------------------------------------- /docs/source/output/_static/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/file.png -------------------------------------------------------------------------------- /docs/source/output/_static/img/MRE_Color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/img/MRE_Color.png -------------------------------------------------------------------------------- /docs/source/output/_static/img/coding.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/img/coding.png -------------------------------------------------------------------------------- /docs/source/output/_static/img/maintenance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/img/maintenance.png -------------------------------------------------------------------------------- /docs/source/output/_static/img/programming.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/img/programming.png -------------------------------------------------------------------------------- /docs/source/output/_static/minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/minus.png -------------------------------------------------------------------------------- /docs/source/output/_static/plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/_static/plus.png -------------------------------------------------------------------------------- /docs/source/output/objects.inv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/output/objects.inv -------------------------------------------------------------------------------- /docs/source/theme/smithy/globaltoc.html: -------------------------------------------------------------------------------- 1 | {# 2 | basic/globaltoc.html 3 | ~~~~~~~~~~~~~~~~~~~~ 4 | #} 5 | 8 | -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/custom-tabs.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Add overrides to how tabs are styled to make them less visually 3 | * obstrusive. Note, however, that this might need to be looked at in 4 | * the future if we ever want to use non-code-tabs. 5 | */ 6 | 7 | /* No need for margin below code samples when in a tab. */ 8 | .code-tab pre { 9 | margin-bottom: 0; 10 | } 11 | 12 | .sphinx-tabs { 13 | margin-top: 1rem; 14 | } 15 | 16 | /* Code tabs should encompass the entire tab. */ 17 | .code-tab.tab { 18 | padding: 0 !important; 19 | } 20 | 21 | .ui.tabular.menu { 22 | border: none; 23 | } 24 | 25 | .ui.tabular.menu .item { 26 | font-size: 0.8em; 27 | font-family: "SFMono-Regular",Consolas,"Liberation Mono",Menlo,Courier,monospace; 28 | text-transform: lowercase; 29 | border: none !important; 30 | } 31 | 32 | .ui.attached.segment.code-tab { 33 | border: none !important; 34 | } 35 | 36 | /* Remove code tab headings and use the same color as code backgrounds */ 37 | .ui.tabular.menu .active.item { 38 | border: none !important; 39 | background-color: inherit; 40 | text-decoration: underline; 41 | font-weight: normal; 42 | } 43 | -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/theme/smithy/static/favicon.png -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/img/MRE_Color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/theme/smithy/static/img/MRE_Color.png -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/img/coding.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/theme/smithy/static/img/coding.png -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/img/maintenance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/theme/smithy/static/img/maintenance.png -------------------------------------------------------------------------------- /docs/source/theme/smithy/static/img/programming.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/docs/source/theme/smithy/static/img/programming.png -------------------------------------------------------------------------------- /docs/source/theme/smithy/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | stylesheet = default.css 4 | 5 | [options] 6 | primary = #232f3E 7 | dark_primary = #232f3E 8 | medium_primary = #232f3E 9 | light_primary = #2BBA9C 10 | 11 | medium_accent = #2BBA9C 12 | dark_accent = #283D3B 13 | site_background = #fff 14 | link_color = #00818e; 15 | regular_font = -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol' 16 | code_font = "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace 17 | -------------------------------------------------------------------------------- /samples/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy of 4 | this software and associated documentation files (the "Software"), to deal in 5 | the Software without restriction, including without limitation the rights to 6 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 7 | the Software, and to permit persons to whom the Software is furnished to do so. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 10 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 11 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 12 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 13 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 14 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 15 | 16 | -------------------------------------------------------------------------------- /samples/NOTICE: -------------------------------------------------------------------------------- 1 | Media Replay Engine Samples 2 | 3 | Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | 5 | ********************** 6 | THIRD PARTY COMPONENTS 7 | ********************** 8 | This software includes third party software subject to the following copyrights: 9 | 10 | aws-amplify under the Apache License Version 2.0 11 | boto3 under the Apache License Version 2.0 12 | botocore under the Apache License Version 2.0 13 | chalice under the Apache License Version 2.0 14 | docker under the Apache License Version 2.0 15 | react under the Massachusetts Institute of Technology license 16 | react-hls-player under the Massachusetts Institute of Technology license 17 | react-scripts under the Massachusetts Institute of Technology license 18 | requests under the Apache License Version 2.0 19 | requests_aws4auth under the Massachusetts Institute of Technology license 20 | urllib3 under the Massachusetts Institute of Technology license -------------------------------------------------------------------------------- /samples/source/custom-resource/requirements.txt: -------------------------------------------------------------------------------- 1 | requests==2.32.0 2 | requests_aws4auth -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/amplify.yml: -------------------------------------------------------------------------------- 1 | version: 1 2 | applications: 3 | - frontend: 4 | phases: 5 | preBuild: 6 | commands: 7 | - curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.5/install.sh | bash 8 | - . ~/.nvm/nvm.sh 9 | - nvm install 20.10.0 10 | - nvm use 20.10.0 11 | - npm install --legacy-peer-deps 12 | build: 13 | commands: 14 | - INLINE_RUNTIME_CHUNK=false npm run build 15 | artifacts: 16 | baseDirectory: build 17 | files: 18 | - '**/*' 19 | cache: 20 | paths: 21 | - node_modules/**/* 22 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/cdk/app.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | from aws_cdk import App, Aspects 5 | from stacks.mre_fan_experience_frontend_stack import MreFanExperienceFrontendStack 6 | from cdk_nag import AwsSolutionsChecks 7 | 8 | app = App() 9 | 10 | MreFanExperienceFrontendStack(app, "mre-fan-experience-frontend-stack") 11 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 12 | 13 | app.synth() 14 | 15 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/cdk/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/cdk/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | aws-cdk.aws-amplify-alpha>=2.24.1a0,<3.0 3 | constructs>=10.0.0 4 | boto3<2.0.0 5 | git-remote-codecommit 6 | cdk-nag==2.28.159 7 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/cdk/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/cdk/stacks/__init__.py -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/env.template: -------------------------------------------------------------------------------- 1 | REACT_APP_REGION= 2 | REACT_APP_BASE_API= 3 | REACT_APP_DATA_PLANE_API= 4 | REACT_APP_USER_POOL_ID= 5 | REACT_APP_APP_CLIENT_ID= 6 | REACT_APP_IDENTITY_POOL_ID= 7 | REACT_APP_CLOUDFRONT_PREFIX= -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/public/favicon.ico -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | } 10 | ], 11 | "start_url": "./index.html", 12 | "display": "standalone", 13 | "theme_color": "#000000", 14 | "background_color": "#ffffff" 15 | } 16 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/App.css: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | @import 'assets/fonts/fonts.css'; 9 | 10 | html, body { 11 | width: 100%; 12 | height: 100%; 13 | margin: 0px; 14 | box-sizing: border-box; 15 | overflow-x: hidden; 16 | overflow: hidden; 17 | } 18 | 19 | div { 20 | display: block; 21 | } 22 | 23 | #root { 24 | height: 100%; 25 | width: 100%; 26 | } -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-medium-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-medium-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-medium-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-medium-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bd-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bd-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bd-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bd-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.ttf -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_bdit-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_he-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_he-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_he-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_he-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_heit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_heit-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_heit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_heit-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.ttf -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_lt-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_ltit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_ltit-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_ltit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_ltit-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rg-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rg-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rg-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rg-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rgit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rgit-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rgit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_rgit-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.ttf -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_th-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_thit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_thit-webfont.woff -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_thit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/fonts/amazonember_thit-webfont.woff2 -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/golf.svg: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | golf 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/soccer_background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/soccer_background.jpg -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/assets/tennis_background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-fan-experience-frontend/src/assets/tennis_background.jpg -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/common/Copyright.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import React from 'react'; 9 | import Typography from "@material-ui/core/Typography"; 10 | import Box from "@material-ui/core/Box"; 11 | 12 | export const Copyright = () => { 13 | return ( 14 | 15 | 16 | {'Copyright © '} 17 | {new Date().getFullYear()} 18 | {' Amazon Web Services, Inc. or its affiliates. All rights reserved'} 19 | 20 | 21 | ); 22 | }; -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/common/routes/AuthenticatedRoute.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import React from "react"; 9 | import { Route, Navigate, useLocation } from "react-router-dom"; 10 | 11 | import {useSessionContext} from "../../contexts/SessionContext"; 12 | 13 | export const AuthenticatedRoute = ({ component: Component, ...rest }) => { 14 | const {isAuthenticated} = useSessionContext(); 15 | const location = useLocation() 16 | return isAuthenticated === true 17 | ? 18 | : 23 | }; 24 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/common/routes/UnauthenticatedRoute.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import React from "react"; 9 | import { Route, Navigate } from "react-router-dom"; 10 | 11 | import {useSessionContext} from "../../contexts/SessionContext"; 12 | 13 | export const UnauthenticatedRoute = ({ component: Component, ...rest }) => { 14 | const {isAuthenticated} = useSessionContext(); 15 | return isAuthenticated === false 16 | ? 17 | : 21 | }; -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/common/utils/utils.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import _ from "lodash"; 9 | 10 | export const formatVideoTime = (seconds) => { 11 | let retVal = "00:00"; 12 | 13 | if (seconds) { 14 | if (seconds < 3600) { 15 | retVal = new Date(seconds * 1000).toISOString().substr(14, 5); 16 | 17 | } 18 | else { 19 | retVal = new Date(seconds * 1000).toISOString().substr(11, 8); 20 | } 21 | 22 | } 23 | 24 | return retVal; 25 | }; 26 | 27 | export const truncateText = (str, textSize) => { 28 | return _.size(str) > textSize ? str.substring(0, textSize) + "..." : str; 29 | }; -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/common/utils/withRouter.js: -------------------------------------------------------------------------------- 1 | import { 2 | useLocation, 3 | useNavigate, 4 | useParams, 5 | } from "react-router-dom"; 6 | 7 | export function withRouter(Component) { 8 | function ComponentWithRouterProp(props) { 9 | let location = useLocation(); 10 | let navigate = useNavigate(); 11 | let params = useParams(); 12 | return ( 13 | 17 | ); 18 | } 19 | 20 | return ComponentWithRouterProp; 21 | } -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/components/Layouts/DemoContainer.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import React from 'react'; 9 | import clsx from 'clsx'; 10 | import {useCookies} from 'react-cookie'; 11 | 12 | 13 | import {makeStyles} from "@material-ui/core/styles"; 14 | 15 | 16 | const useStyles = makeStyles((theme) => ({ 17 | demoContainer: { 18 | display: 'flex', 19 | flexDirection: 'column', 20 | height: '100%', 21 | backgroundPosition: 'right bottom', 22 | backgroundRepeat: 'no-repeat' 23 | } 24 | })); 25 | 26 | function DemoContainer(props) { 27 | const classes = useStyles(); 28 | const {bgType, className, ...rest} = props; 29 | const [cookies, setCookie] = useCookies(); 30 | 31 | return ( 32 | <> 33 |
34 | {props.children} 35 |
36 | 37 | ) 38 | } 39 | 40 | export default DemoContainer; 41 | 42 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/config.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | export default { 9 | "APP_TITLE": "MRE Fan Experience", 10 | "s3": { 11 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 12 | "BUCKET": "" 13 | }, 14 | "apiGateway": { 15 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 16 | "REACT_APP_BASE_API": process.env.REACT_APP_BASE_API, 17 | "REACT_APP_DATA_PLANE_API": process.env.REACT_APP_DATA_PLANE_API 18 | }, 19 | "cognito": { 20 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 21 | "REACT_APP_USER_POOL_ID": process.env.REACT_APP_USER_POOL_ID, 22 | "REACT_APP_APP_CLIENT_ID": process.env.REACT_APP_APP_CLIENT_ID, 23 | "REACT_APP_IDENTITY_POOL_ID": process.env.REACT_APP_IDENTITY_POOL_ID 24 | } 25 | }; 26 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/containers/NotFound/NotFound.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import React from "react"; 9 | 10 | //@todo spice it up with gopher graphic 11 | export default () => { 12 | return ( 13 |
14 |

Sorry, page not found!

15 |
16 | ); 17 | } 18 | -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/contexts/SessionContext.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | import { useContext, createContext } from "react"; 9 | 10 | export const SessionContext = createContext(null); 11 | 12 | export function useSessionContext() { 13 | return useContext(SessionContext); 14 | } -------------------------------------------------------------------------------- /samples/source/mre-fan-experience-frontend/src/index.css: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | * * SPDX-License-Identifier: MIT-0 5 | * 6 | */ 7 | 8 | body { 9 | height: 100%; 10 | margin: 0; 11 | -webkit-font-smoothing: antialiased; 12 | -moz-osx-font-smoothing: grayscale; 13 | } -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingClassificationModel/README.md: -------------------------------------------------------------------------------- 1 | # Audio Embedding Classification Model 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | This model takes the output from AudioEmbeddingModel, and classify the audio embeddings into predefined classes 8 | 9 | 10 | **Use Cases**: 11 | - Ace and double fault serve classification in Tennis demo 12 | - Any audio embedding classification 13 | 14 | **Model Type**: 15 | - Custom model trained by Amazon SageMaker Autopilot 16 | 17 | **Methods for training data collection and annotation** 18 | - Get output from AudioEmbeddingModel and save as a CSV file 19 | - Add a AUDIO_CLASS column in the CSV file and annotate each pose with a class name 20 | - An end-to-end solution for audio classification is under development 21 | 22 | **Methods for model training** 23 | - Create an Autopilot job. See details in the Notebook 24 | 25 | **Methods for model hosting** 26 | - Autopilot job will host an endpoint for the best candiate job 27 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingClassificationModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "AudioEmbeddingClassificationModel", 3 | "Description": "Classify audio embeddings into predefined classes", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "SAGEMAKER_HOSTED_MODEL_ENDPOINT" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingModel/DockerImage/config.properties: -------------------------------------------------------------------------------- 1 | vmargs=-Xmx128m -XX:-UseLargePages -XX:+UseG1GC -XX:MaxMetaspaceSize=32M -XX:MaxDirectMemorySize=10m -XX:+ExitOnOutOfMemoryError 2 | model_store=/opt/ml/model 3 | load_models=ALL 4 | inference_address=http://0.0.0.0:8080 5 | management_address=http://0.0.0.0:8081 6 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingModel/DockerImage/mms-entrypoint.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | import shlex 5 | import subprocess 6 | import sys 7 | 8 | 9 | if sys.argv[1] == 'serve': 10 | from sagemaker_mxnet_serving_container import serving 11 | serving.main() 12 | else: 13 | subprocess.check_call(shlex.split(' '.join(sys.argv[1:]))) 14 | 15 | # prevent docker exit 16 | subprocess.call(['tail', '-f', '/dev/null']) 17 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingModel/README.md: -------------------------------------------------------------------------------- 1 | # Audio Embedding Model # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | This model endpoint uses [OpenL3](https://github.com/marl/openl3) library to embed audio signals into vectors. 8 | This endpoint is created based on a BYOC(Bring Your Own Custom) inference image. 9 | 10 | 11 | **Use Cases**: 12 | - Ace serve and double fault serve audio embedding 13 | - Any audio classification use cases based on audio embedding 14 | 15 | **Model Type**: 16 | - Open-source models hosted as Amazon SageMaker endpoint 17 | 18 | **Methods for training data collection and annotation** 19 | N/A 20 | 21 | **Methods for model training** 22 | N/A 23 | 24 | **Methods for model hosting** 25 | -Build a docker image based on Multi-Model-Server by runing the build_your_custom_image.sh 26 | -Create SageMaker model based on the BYOC inference image 27 | -Create SgaeMaker endpoint based on the SageMaker model 28 | -See details in the notebook 29 | 30 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "AudioEmbeddingModel", 3 | "Description": "Embed the audio signal with OpenL3 library", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "SAGEMAKER_HOSTED_MODEL_ENDPOINT" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioEmbeddingModel/model.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-model-samples/Models/AudioEmbeddingModel/model.tar.gz -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioSpectrumClassificationModel/README.md: -------------------------------------------------------------------------------- 1 | # Audio Embedding Classification Model 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | - Classify audio spectrum into predefined classes 8 | 9 | **Use Cases**: 10 | - Audio scene classification in the Tennis demo 11 | - Any audio spectrum classification 12 | 13 | **Model Type**: 14 | - Custom model trained by Amazon SageMaker Autopilot 15 | 16 | **Methods for training data collection and annotation** 17 | - See details in the notebook 18 | - An end-to-end solution for audio classification is under development 19 | 20 | **Methods for model training** 21 | - Create an SageMaker Autopilot job. 22 | 23 | **Methods for model hosting** 24 | - SageMaker Autopilot job will host an endpoint for the best candiate job 25 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/AudioSpectrumClassificationModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "AudioSpectrumClassificationModel", 3 | "Description": "Classify audio spectrum into predefined classes", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "SAGEMAKER_HOSTED_MODEL_ENDPOINT" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/PoseClassificationModel/README.md: -------------------------------------------------------------------------------- 1 | # Pose Classification Model # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | This model takes the output from PoseKeypointDetectionModel, and classify human pose into predefined classes 8 | 9 | 10 | **Use Cases**: 11 | - Pointing pose detection in the Soccer demo 12 | - Serving pose detection in the Tennis demo 13 | - Any human pose classification 14 | 15 | **Model Type**: 16 | - Custom model trained by Amazon SageMaker Autopilot 17 | 18 | **Methods for training data collection and annotation** 19 | - Get output from PoseKeypointsExtractionModel and save it as a CSV file 20 | - Add a POSE_CLASS column in the CSV file and annotate each pose with a class name 21 | - An end-to-end solution for pose classification is under development 22 | 23 | **Methods for model training** 24 | - Create an SageMaker Autopilot job. See details in the Notebook 25 | 26 | **Methods for model hosting** 27 | - SageMaker Autopilot job will host an endpoint for the best candiate job 28 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/PoseClassificationModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "PoseClassificationModel", 3 | "Description": "Human pose Classifier", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "SAGEMAKER_HOSTED_MODEL_ENDPOINT" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/PoseKeypointsExtractionModel/README.md: -------------------------------------------------------------------------------- 1 | # Pose Keypoints Extraction Model # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | This model endpoint contains two public models. [YOLOv3](https://arxiv.org/abs/1804.02767) model is used for human detection, and [SimplePose](https://arxiv.org/abs/1911.10529) model for keypoints extraction. 8 | The model is created based on SageMaker MXNetModel image. 9 | 10 | 11 | **Use Cases**: 12 | - Pointing pose detection in the Soccer demo 13 | - Volley detection in the Tennis demo 14 | - Any human object/pose related detection 15 | 16 | **Model Type**: 17 | - Public Models hosted as Amazon SageMaker endpoint 18 | 19 | **Methods for training data collection and annotation** 20 | N/A 21 | 22 | **Methods for model training** 23 | N/A 24 | 25 | **Methods for model hosting** 26 | -Download YOLOv3 and SimplePose models from GluonCV model zoo 27 | -Create SageMaker model based on these two public models 28 | -Create SageMaker endpoint based on the SageMaker model 29 | -See details in the notebook 30 | 31 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/PoseKeypointsExtractionModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "PoseKeypointsExtractionModel", 3 | "Description": "Detect human figure from the frame images and get pose key points", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "SAGEMAKER_HOSTED_MODEL_ENDPOINT" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/PoseKeypointsExtractionModel/images/soccer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-model-samples/Models/PoseKeypointsExtractionModel/images/soccer.png -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/SceneClassificationModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "SceneClassificationModel", 3 | "Description": "Doing contextual scene classification for frame images.It could be custom models trained from AWS AI services or from Amazon SageMaker", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "arn:aws:rekognition:AWS_REGION:AWS_ACCOUNT:project/REKCL-PROJECT-NAME/version/REKCL-VERSION-NUMBER" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/SceneClassificationModel/output.manifest: -------------------------------------------------------------------------------- 1 | {"source-ref":"s3://${BUCKET_NAME}/PATH/TO/IMAGE.png","auto-label":1,"auto-label-metadata":{"confidence":1,"job-name":"labeling-job/auto-label","class-name":"${LABEL_NAME}","human-annotated":"yes","creation-date":"2021-07-16T17:54:12.719","type":"groundtruth/image-classification"}} 2 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/ScoreBoxDetectionModel/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "ScoreBoxDetectionModel", 3 | "Description": "Detect score box from the frame images", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "All" 7 | ], 8 | "Endpoint": "arn:aws:rekognition:AWS_REGION:AWS_ACCOUNT:project/REKCL-PROJECT-NAME/version/REKCL-VERSION-NUMBER" 9 | } 10 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/ScoreBoxDetectionModel/output.manifest: -------------------------------------------------------------------------------- 1 | {"source-ref":"s3://${BUCKET_NAME}/PATH/TO/IMAGE.png","Tennis-scorebox_BB":{"annotations":[{"left":112,"top":593,"width":258,"height":68,"class_id":0}],"image_size":[{"width":1280,"height":720,"depth":3}]},"Tennis-scorebox_BB-metadata":{"job-name":"labeling-job/Tennis-scorebox_BB","class-map":{"0":"scorebox"},"human-annotated":"yes","objects":[{"confidence":1}],"creation-date":"2021-09-21T21:48:00.497Z","type":"groundtruth/object-detection"}} 2 | -------------------------------------------------------------------------------- /samples/source/mre-model-samples/Models/template_model_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "string", 3 | "Description": "string", 4 | "ContentGroups": "list", 5 | "Endpoint": "string", 6 | "PluginClass": ["Classifier"|"Optimizer"|"Featurer"|"Labeler"] 7 | } 8 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioPeaks/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "DetectAudioPeaks.lambda_handler", 4 | "MemorySize": 2048, 5 | "TimeoutSecs": 30, 6 | "Layers": ["ffmpeg", "numpy", "scipy"] 7 | }, 8 | "MRE": { 9 | "Plugin": { 10 | "Name": "DetectAudioPeaks", 11 | "Description": "This plugin attempts to detect where peaks in audio are occuring in an audio track by calculating the rolling average and standard deviation of audio amplitudes.", 12 | "Class": "Featurer", 13 | "ExecutionType": "Sync", 14 | "SupportedMediaType": "Video", 15 | "ContentGroups": ["All"], 16 | "ExecuteLambdaQualifiedARN": "", 17 | "Configuration": { 18 | "TrackNumber": "1", 19 | "bin_size_seconds": "5", 20 | "look_back_bin_cnt": "1", 21 | "num_stddevs_filter": "1", 22 | "filter_lowcut": "1000", 23 | "filter_highcut": "4000" 24 | }, 25 | "OutputAttributes": { 26 | "Label": {"Description": ""} 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioPeaks/requirements.txt: -------------------------------------------------------------------------------- 1 | requests==2.32.2 2 | ffmpeg-python==0.2.0 3 | soundfile 4 | scipy 5 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioScene/requirements.txt: -------------------------------------------------------------------------------- 1 | audio2numpy 2 | matplotlib 3 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioSilence/README.md: -------------------------------------------------------------------------------- 1 | # DetectAudioSilence # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin uses FFMPEG to determine where silence exists within an audio track. This can be used for optimizing in/out placements. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | - Audio (In Development) 13 | 14 | **Use Cases**: 15 | - Any segment that can benefit from refinement of the in/out placement. 16 | 17 | **Dependencies**: 18 | - MRE Helper libraries 19 | - FFMPEG >> setup as a Lambda Layer 20 | 21 | **ML Model dependencies**: 22 | - None 23 | 24 | **Other plugin dependencies**: 25 | - None 26 | 27 | **Parameter inputs**: 28 | - TrackNumber >> Audio track from video that is being used for calculations. 29 | - silence_threshold_db >> Threshold for audio silence in decibels. A value between -30 and -60 would be reasonable. 30 | - silence_duration_sec >> Number of seconds that the audio level must be sustained in order to be detected. 31 | 32 | **Output attributes**: 33 | - Label >> Name of the feature to be detected in this plugin. 34 | 35 | **IAM permissions (least privilege)**: 36 | - None 37 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioSilence/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "DetectAudioSilence.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 60, 6 | "Layers": ["ffmpeg"] 7 | }, 8 | "MRE": { 9 | "Plugin": { 10 | "Name": "DetectAudioSilence", 11 | "Description": "This plugin attempts to detect where silence is occurring in an audio track by using ffmpeg.", 12 | "Class": "Featurer", 13 | "ExecutionType": "Sync", 14 | "SupportedMediaType": "Video", 15 | "ContentGroups": ["All"], 16 | "ExecuteLambdaQualifiedARN": "", 17 | "Configuration": { 18 | "silence_threshold_db": "-50", 19 | "silence_duration_sec": "2", 20 | "bias": "safe range", 21 | "TrackNumber": 1 22 | }, 23 | "OutputAttributes": {"Label": {"Description": ""}} 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectAudioSilence/requirements.txt: -------------------------------------------------------------------------------- 1 | ffmpeg-python==0.2.0 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectCameraScene/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectCameraScene.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectCameraScene/requirements.txt: -------------------------------------------------------------------------------- 1 | numpy 2 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectFaces/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectFaces.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectFaces/requirements.txt: -------------------------------------------------------------------------------- 1 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPassThrough1/README.md: -------------------------------------------------------------------------------- 1 | # Detect DetectPassThrough1 # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | Simple pass through detector to baseline MRE performance. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Baseline testing 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - none 21 | 22 | **Other plugin dependencies**: 23 | - none 24 | 25 | **Parameter inputs**: 26 | - none 27 | 28 | **Output attributes**: 29 | - Label >> N/A 30 | - Attribute1 >> Always True 31 | 32 | 33 | **IAM permissions (least privilege)**: 34 | - None 35 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPassThrough1/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "DetectPassThrough1.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 120 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "DetectPassThrough1", 10 | "Description": "Simple pass through detector to baseline MRE performance. With one output attribute.", 11 | "Class": "Featurer", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "OutputAttributes": { 19 | "Label": { 20 | "Description": "N/A" 21 | }, 22 | "Attribute1": { 23 | "Description": "A dummy attribute" 24 | } 25 | } 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPassThrough100/README.md: -------------------------------------------------------------------------------- 1 | # Detect DetectPassThrough100 # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | Simple pass through detector to baseline MRE performance using 100 output attributes. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Baseline testing 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - none 21 | 22 | **Other plugin dependencies**: 23 | - none 24 | 25 | **Parameter inputs**: 26 | - none 27 | 28 | **Output attributes**: 29 | - Label >> N/A 30 | - Attribute1 >> Always True 31 | ... 32 | - Attribute100 >> Always True 33 | 34 | **IAM permissions (least privilege)**: 35 | - None 36 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPose/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectPose.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPose/README.md: -------------------------------------------------------------------------------- 1 | # DetectPose # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin classifier pose keypoints into predefined classes. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Trick shot detection (behind the back tennis shot). 15 | - Player excitement (hands up in the air). 16 | - Thrilling action of a soccer goalie blocking a shot flying in the air. 17 | - Tennis player serving pose. 18 | 19 | **Dependencies**: 20 | - MRE Helper libraries 21 | - Scipy 22 | - OpenCV 23 | 24 | **ML Model dependencies**: 25 | - PoseClassificationModel 26 | 27 | **Other plugin dependencies**: 28 | - DetectPoseKeypoints 29 | 30 | **Parameter inputs**: 31 | - minimum_confidence >> minimum confidence for classification. 32 | - KeypointList >> list of keypoints will be used for the classification. 33 | 34 | **Output attributes**: 35 | - Label >> Name of the feature be detected in this plugin. 36 | - PoseDetection >> Detected pose class. 37 | 38 | **IAM permissions (least privilege)**: 39 | - sagemaker:InvokeEndpoint * 40 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPose/requirements.txt: -------------------------------------------------------------------------------- 1 | scipy 2 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPoseKeypoints/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectPoseKeypoints.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPoseKeypoints/README.md: -------------------------------------------------------------------------------- 1 | # DetectPoseKeypoints # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin detects keypoints for a pose estimation. Pose estimation is very useful to detect key moments where body position is the indicator. The data generated by this plugin is intended to be further classified in a second featurer plugin that is specific to your content. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Trick shot detection (behind the back tennis shot) 15 | - Player excitement (hands up in the air) 16 | - Thrilling action of a soccer goalie blocking a shot flying in the air 17 | 18 | **Dependencies**: 19 | - MRE Helper libraries 20 | - Scipy 21 | - OpenCV 22 | 23 | **ML Model dependencies**: 24 | - PoseKeypointExtractionModel 25 | 26 | **Other plugin dependencies**: 27 | - None 28 | 29 | **Parameter inputs**: 30 | - minimum_confidence >> Minimum Confidence for keypoints extraction 31 | 32 | 33 | **Output attributes**: 34 | - keypoints >> the point positions determined by the algorithm 35 | - frameId >> used for debug 36 | 37 | **IAM permissions (least privilege)**: 38 | - sagemaker:InvokeEndpoint 39 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPoseKeypoints/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "DetectPoseKeypoints.lambda_handler", 4 | "MemorySize": 3008, 5 | "TimeoutSecs": 240, 6 | "IAMPolicyDocument": [ 7 | { 8 | "Actions": [ 9 | "sagemaker:InvokeEndpoint" 10 | ], 11 | "Resources": [ 12 | "*" 13 | ] 14 | } 15 | ], 16 | "Layers": [ 17 | "scipy", 18 | "opencv-python" 19 | ] 20 | }, 21 | "MRE": { 22 | "Plugin": { 23 | "Name": "DetectPoseKeypoints", 24 | "Description": "This plugin detects keypoints for a pose estimation.", 25 | "Class": "Featurer", 26 | "ExecutionType": "SyncModel", 27 | "SupportedMediaType": "Video", 28 | "ModelEndpoints": [ 29 | { 30 | "Name": "PoseKeypointsExtractionModel" 31 | } 32 | ], 33 | "ContentGroups": [ 34 | "Soccer" 35 | ], 36 | "ExecuteLambdaQualifiedARN": "", 37 | "Configuration": { 38 | "minimum_confidence": "0.9" 39 | }, 40 | "OutputAttributes": { 41 | "Label": { 42 | "Description": "Add a desc" 43 | } 44 | } 45 | } 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectPoseKeypoints/requirements.txt: -------------------------------------------------------------------------------- 1 | scipy 2 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSceneChange/README.md: -------------------------------------------------------------------------------- 1 | # DetectSceneChange # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin uses FFMPEG to determine where scene changes are occurring in video. This can be used for optimizing in/out placements. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Any segment that can benefit from refinement of the in/out placement. 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | - ffmpeg >> setup as a Lambda Layer 19 | 20 | **ML Model dependencies**: 21 | - None 22 | 23 | **Other plugin dependencies**: 24 | - None 25 | 26 | **Parameter inputs**: 27 | - scene_threshold >> Range of sane value is between 0.3 and 0.5 per the FFMPEG docs. This value affects the threshold for change detection. 28 | 29 | **Output attributes**: 30 | - Label >> Name of the feature to be detected in this plugin. 31 | 32 | **IAM permissions (least privilege)**: 33 | - None 34 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSceneChange/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "DetectSceneChange.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 60, 6 | "Layers": [ 7 | "ffmpeg" 8 | ] 9 | }, 10 | "MRE": { 11 | "Plugin": { 12 | "Name": "DetectSceneChange", 13 | "Description": "A more professional segment/clip can be achieved by applying an optimization of the in/out placements. This plugin requires one or many featurer plugins to be configured as dependencies.", 14 | "Class": "Featurer", 15 | "ExecutionType": "Sync", 16 | "SupportedMediaType": "Video", 17 | "ContentGroups": [ 18 | "All" 19 | ], 20 | "ExecuteLambdaQualifiedARN": "", 21 | "Configuration": { 22 | "scene_threshold": "0.4", 23 | "bias": "safe range" 24 | }, 25 | "OutputAttributes": { 26 | "Label": { 27 | "Description": "" 28 | } 29 | } 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSceneChange/requirements.txt: -------------------------------------------------------------------------------- 1 | ffmpeg-python==0.2.0 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectShotsByRekognitionVideo/requirements.txt: -------------------------------------------------------------------------------- 1 | ffmpeg-python==0.2.0 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSoccerScene/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectSoccerScene.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSoccerScene/requirements.txt: -------------------------------------------------------------------------------- 1 | scipy 2 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectSpeech/requirements.txt: -------------------------------------------------------------------------------- 1 | ffmpeg-python==0.2.0 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectTennisScoreBoxData/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM public.ecr.aws/lambda/python:3.11-x86_64 as app 2 | 3 | RUN yum -y install \ 4 | libsndfile \ 5 | git \ 6 | unzip 7 | 8 | #install aws cli to run the aws commands below 9 | RUN pip install --upgrade awscli 10 | 11 | # install lambda function 12 | COPY *".py" "${LAMBDA_TASK_ROOT}" 13 | COPY *".json" "${LAMBDA_TASK_ROOT}" 14 | COPY *".md" "${LAMBDA_TASK_ROOT}" 15 | COPY "mre_plugin_helper/python/lib/python3.11/site-packages/." "${LAMBDA_TASK_ROOT}" 16 | COPY requirements.txt . 17 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 18 | 19 | COPY requirements.txt . 20 | RUN pip3 install -r requirements.txt --target "${LAMBDA_TASK_ROOT}" 21 | 22 | CMD ["DetectTennisScoreBoxData.lambda_handler"] -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectTennisScoreBoxData/README.md: -------------------------------------------------------------------------------- 1 | # DetectTennisScoreBoxData # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin detects scorebox from the frame images. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Score detection 15 | - Game point/Set point/Match point detection 16 | - Serving player detection 17 | 18 | **Dependencies**: 19 | - MRE Helper libraries 20 | - Numpy 21 | - OpenCV 22 | 23 | **ML Model dependencies**: 24 | - ScoreBoxDectionModel 25 | 26 | **Other plugin dependencies**: 27 | - None 28 | 29 | **Parameter inputs**: 30 | - minimum_monfidence >> Minimum Confidence for keypoints extraction. 31 | 32 | 33 | **Output attributes**: 34 | - Label >> Name of the plugin. 35 | - Server >> The server player's name in tennis demo. 36 | - Score >> The raw score read from the score box. 37 | 38 | **IAM permissions (least privilege)**: 39 | - rekognition:DetectCustomLabels * 40 | - rekognition:DetectText * 41 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectTennisScoreBoxData/requirements.txt: -------------------------------------------------------------------------------- 1 | numpy 2 | opencv-python-headless==4.8.1.78 -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/DetectTennisVolley/README.md: -------------------------------------------------------------------------------- 1 | # DetectTennisVolley # 2 | 3 | **MRE Plugin Class** 4 | - Featurer 5 | 6 | **Description**: 7 | 8 | This plugin detects a player is doing volley shots in the tennis match. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Volley shots detection 15 | - Human enter/exit a bounded area detection 16 | 17 | **Dependencies**: 18 | - MRE Helper libraries 19 | - Scipy 20 | - OpenCV 21 | 22 | **ML Model dependencies**: 23 | - SceneClassificationModel 24 | 25 | **Other plugin dependencies**: 26 | 27 | **Parameter inputs**: 28 | - minimum_confidence >> minimum confidence for classification 29 | - vl >> Left boundary of the volley zone 30 | - vr >> Right boundary of the volley zone 31 | - vt >> Top boundary of the volley zone 32 | - vb >> Bottom boundary of the volley zone 33 | 34 | **Output attributes**: 35 | - Label >> Name of the feature be detected in this plugin 36 | - Volley >> 1 if volley has been detected, 0 otherwise. 37 | 38 | **IAM permissions (least privilege)**: 39 | - rekognition:DetectCustomLabels * 40 | - rekognition:DetectLabels * 41 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/LabelBasic/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "LabelBasic.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "LabelBasic", 10 | "Description": "This is start code for a simple labeler plugin.", 11 | "Class": "Labeler", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "Configuration": { 18 | "chunk_noun": "Detection" 19 | }, 20 | "ExecuteLambdaQualifiedARN": "" 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/LabelPassThrough/README.md: -------------------------------------------------------------------------------- 1 | # LabelBasic # 2 | 3 | **MRE Plugin Class** 4 | - Labeler 5 | 6 | **Description**: 7 | 8 | A way to baseline framework latency with a trivial labeling task. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Any segment that can benefit from refinement of the in/out placement. 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - None 24 | 25 | **Parameter inputs**: 26 | - None 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/LabelPassThrough/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "LabelPassThrough.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "LabelPassThrough", 10 | "Description": "A way to baseline framework latency with a trivial labeling task.", 11 | "Class": "Labeler", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "" 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/LabelTennisAceDoubleFault/README.md: -------------------------------------------------------------------------------- 1 | # LabelTennisAceDoubleFault # 2 | 3 | **MRE Plugin Class** 4 | - Labeler 5 | 6 | **Description**: 7 | 8 | This plugin classifies a segment to be ace serve, double fault, or regular rally play 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Ace/Double Fault detection 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | - Scipy 19 | - OpenCV 20 | 21 | **ML Model dependencies**: 22 | - AudioEmbeddingModel 23 | - AudioEmbeddingClassificationModel 24 | 25 | **Other plugin dependencies**: 26 | - None 27 | 28 | **Parameter inputs**: 29 | - None 30 | 31 | **Output attributes**: 32 | - Label >> Name of the feature be detected in this plugin 33 | - Ace >> Boolean value for ace serve 34 | - DoubleFault >> Boolean value for double fault serve 35 | 36 | **IAM permissions (least privilege)**: 37 | - sagemaker:InvokeEndpoint * 38 | - s3:GetObject * 39 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/LabelTennisScore/README.md: -------------------------------------------------------------------------------- 1 | # LabelTennisScore # 2 | 3 | **MRE Plugin Class** 4 | - Labeler 5 | 6 | **Description**: 7 | 8 | This plugin extract score from the scorebox detection output. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Game point/Set point/Match point detection 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - DetectTennisScoreBoxData 24 | 25 | **Parameter inputs**: 26 | - dependent_plugin_name >> Name if the plugin that this plugin is getting its score data from. 27 | 28 | **Output attributes**: 29 | - Label >> Name of the feature to be detected in this plugin. 30 | - Score >> Score detected by plugin. 31 | - BreakPoint >> Boolean value for breakpoint. 32 | - GamePoint >> Boolean value for gamepoint. 33 | - SetPoint >> Boolean value for setpoint. 34 | - MatchPoint >> Boolean value for matchpoint. 35 | 36 | **IAM permissions (least privilege)**: 37 | - None 38 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/OptimizePassThrough/README.md: -------------------------------------------------------------------------------- 1 | # OptimizePassThrough # 2 | 3 | **MRE Plugin Class** 4 | - Optimizer 5 | 6 | **Description**: 7 | 8 | A way to baseline framework latency with a trivial optimization task. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Baselining MRE performance. 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - none 21 | 22 | **Other plugin dependencies**: 23 | - none 24 | 25 | **Parameter inputs**: 26 | - none 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/OptimizePassThrough/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "OptimizePassThrough.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "OptimizePassThrough", 10 | "Description": "A way to baseline framework latency with a trivial optimization task.", 11 | "Class": "Optimizer", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "" 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/OptimizeSegment/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "OptimizeSegment.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "OptimizeSegment", 10 | "Description": "A more professional segment/clip can be achieved by applying an optimization of the in/out placements. This plugin requires one or many featurer plugins to be configured as dependencies.", 11 | "Class": "Optimizer", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "optimization_search_window_sec": "5" 20 | }, 21 | "DependentPlugins": [ 22 | "DetectSceneChange" 23 | ] 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/README.md: -------------------------------------------------------------------------------- 1 | **MRE Plugin Samples** 2 | 3 | Plugin samples are provided to speed development and provide insights into different approaches for solving various video and audio processing needs. Plugins are written in Python 3.11 since the required MRE Helper library (Lambda Layer) is tested for this version. 4 | 5 | Each plugin is organized in this repository in a folder based on it's unique name. 6 | 7 | Each plugin folder contains: 8 | - README.md 9 | - config.json 10 | - some-lambda-function.py 11 | - optional-other-files 12 | 13 | The plugin README should include the following details: 14 | - The intended MRE Plugin Class 15 | - Description of what the plugin is designed to do 16 | - Use cases that describe how it was applied in earlier use 17 | - Python dependencies with notes as to which need to be a custom Lambda Layer 18 | - Model dependencies 19 | - Other plugin dependencies referenced by name in this repo 20 | - Expected parameter inputs and their purpose with sample values 21 | - Expected output attributes (the data produced) 22 | - IAM permissions needed (least privilege) 23 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByCommercials/README.md: -------------------------------------------------------------------------------- 1 | # SegmentByCommercials # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | This plugin segments the video by commercial breaks. It uses the results from shot detection and applies an average filter on shot length. Based on the threshold value set by the user, the plugin will filter out segments with shorter shot length, which are commercials. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Interviews, keynotes, or sports that has commercials in it. 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - A shot detection plugin (featurer class) for your content, for example, DetectShotsByRekognitionVideo. 24 | 25 | **Parameter inputs**: 26 | - MIN_DURATION: Minimun length of a shot. 27 | - WINDOW_SIZE: The window size used to run average filter. 28 | - THRESHOLD_VAL: The threshold value to detect commercials. 29 | - THRESHOLD_LEN: The threshold length to identify commercials. 30 | 31 | **Output attributes**: 32 | - None 33 | 34 | **IAM permissions (least privilege)**: 35 | - None 36 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByCommercials/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentByCommercials.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 60 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentByCommercials", 10 | "Description": "Using the results from shot detection to segment vidoes", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "MIN_DURATION": 0, 20 | "WINDOW_SIZE": 10, 21 | "THRESHOLD_VAL": 2, 22 | "THRESHOLD_LEN": 3 23 | }, 24 | "DependentPlugins": [ 25 | "DetectShotsByRekognitionVideo" 26 | ] 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByKeyMoment/README.md: -------------------------------------------------------------------------------- 1 | # LabelTennisScore # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | "This plugin attempts to segment footage by key moments by using data taken from the detector and adding a buffer to detected moments" 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Goal Scored/Game point/Set point/Match point detection 15 | 16 | **Dependencies**: 17 | - Dependencies are required for this plugin due to the nature of the framework. Whichever detector you want to segment by, use that as the dependency 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - A detection plugin (featurer class) for your content, for example, DetectSceneChange. 24 | 25 | **Parameter inputs**: 26 | - chunk_to_segment_ratio >> Used to calculate how much footage is added before and after the key moment as a buffer for the viewer. 27 | 28 | **Output attributes**: 29 | - Label >> Name of the feature to be detected in this plugin. 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByKeyMoment/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentByKeyMoment.lambda_handler", 4 | "MemorySize": 128, 5 | "TimeoutSecs": 3 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentByKeyMoment", 10 | "Description": "This plugin attempts to detect key moments in footage, such as when a score is made", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "chunk_to_segment_ratio": "1" 20 | }, 21 | "OutputAttributes": { 22 | "Label": { 23 | "Description": "" 24 | } 25 | }, 26 | "DependentPlugins": [ 27 | "DetectAudioPeaks" 28 | ] 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentBySceneChange/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentBySceneChange.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 60 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentBySceneChange", 10 | "Description": "Using camera angles or scene classification values, use pattern sequences to identify the start and end of a segment/clip.", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "start_seq": "[['near','far'],['topview','far']]", 20 | "end_seq": "[['far','near'],['far','topview']]", 21 | "padding_seconds": "1" 22 | }, 23 | "DependentPlugins": [ 24 | "DetectCameraScene" 25 | ] 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentBySceneChangeWithOffset/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentBySceneChangeWithOffset.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 60 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentBySceneChangeWithOffset", 10 | "Description": "Using camera angles or scene classification values, use pattern sequences to identify the start and end of a segment/clip.", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "start_seq": "[{'offset':2, 'pattern':[['Near_View','Logo_View'],['Far_View','Logo_View']] }, {'offset':1,'pattern':[['Near_View','Far_View']]}]", 20 | "end_seq": "[{'offset':2, 'pattern':[['Logo_View','Near_View'],['Logo_View','Far_View']] }, {'offset':1,'pattern':[['Far_View','Near_View']]}]", 21 | "padding_seconds": "1" 22 | }, 23 | "DependentPlugins": [ 24 | "DetectSoccerScene" 25 | ] 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByShot/README.md: -------------------------------------------------------------------------------- 1 | # SegmentByShot # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | This plugin is useful to segment the video based on shot detection, for examples, interviews or keynotes recording, in which the scene change is less frequent. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - Interviews, keynotes, or sports in which scene change is less frequent. 15 | 16 | **Dependencies**: 17 | - MRE Helper libraries 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - A shot detection plugin (featurer class) for your content, for example, DetectShotsByRekognitionVideo 24 | 25 | **Parameter inputs**: 26 | - MIN_DURATION: Minimun duration of the shots 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentByShot/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentByShot.lambda_handler", 4 | "MemorySize": 512, 5 | "TimeoutSecs": 60 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentByShot", 10 | "Description": "Using the results from shot detection to segment vidoes", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "MIN_DURATION": 0 20 | }, 21 | "DependentPlugins": [ 22 | "DetectShotsByRekognitionVideo" 23 | ] 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentFromTranscription/README.md: -------------------------------------------------------------------------------- 1 | # SegmentFromTranscription # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | This plugin creates segments based on spoken phrases identified from transcribed text. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - To perform very basic functional tests of the MRE control plane. 15 | 16 | **Dependencies**: 17 | - None 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - DetectSpeech 24 | 25 | **Parameter inputs**: 26 | - None 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentFromTranscription/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentFromTranscription.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentFromTranscription", 10 | "Description": "This plugin creates segments based on spoken phrases identified from transcribed text.", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | 20 | }, 21 | "DependentPlugins": [ 22 | "DetectSpeech" 23 | ] 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentPassThrough/README.md: -------------------------------------------------------------------------------- 1 | # SegmentPassThrough # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | This plugin is used to test MRE in a simple way by creating segments for each chunk based on time. It creates one segment for each chunk based on the ratio parameter value provided in the configuration. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - To perform very basic functional tests of the MRE control plane. 15 | 16 | **Dependencies**: 17 | - None 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - None 24 | 25 | **Parameter inputs**: 26 | - chunk_to_segment_ratio >> What the approximate length the segment will be relative to the chunk length 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentPassThrough/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentPassThrough.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentPassThrough", 10 | "Description": "This plugin is used to test MRE in a simple way by creating segments for each chunk based on time.", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "chunk_to_segment_ratio": "0.5" 20 | } 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentPassThrough100/README.md: -------------------------------------------------------------------------------- 1 | # SegmentPassThrough100 # 2 | 3 | **MRE Plugin Class** 4 | - Segmenter 5 | 6 | **Description**: 7 | 8 | This plugin is used to test MRE in a simple way by creating segments for each chunk based on time. It creates one segment for each chunk based on the ratio parameter value provided in the configuration. It has a different dependency than the original sample. 9 | 10 | **Applies to Media Type**: 11 | - Video 12 | 13 | **Use Cases**: 14 | - To perform very basic functional tests of the MRE control plane. 15 | 16 | **Dependencies**: 17 | - None 18 | 19 | **ML Model dependencies**: 20 | - None 21 | 22 | **Other plugin dependencies**: 23 | - None 24 | 25 | **Parameter inputs**: 26 | - chunk_to_segment_ratio >> What the approximate length the segment will be relative to the chunk length 27 | 28 | **Output attributes**: 29 | - None 30 | 31 | **IAM permissions (least privilege)**: 32 | - None 33 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/Plugins/SegmentPassThrough100/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Lambda": { 3 | "Handler": "SegmentPassThrough100.lambda_handler", 4 | "MemorySize": 256, 5 | "TimeoutSecs": 30 6 | }, 7 | "MRE": { 8 | "Plugin": { 9 | "Name": "SegmentPassThrough100", 10 | "Description": "This plugin is used to test MRE in a simple way by creating segments for each chunk based on time.", 11 | "Class": "Classifier", 12 | "ExecutionType": "Sync", 13 | "SupportedMediaType": "Video", 14 | "ContentGroups": [ 15 | "All" 16 | ], 17 | "ExecuteLambdaQualifiedARN": "", 18 | "Configuration": { 19 | "chunk_to_segment_ratio": "0.5" 20 | } 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/cdk/app.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | #!/usr/bin/env python3 5 | 6 | import os 7 | from aws_cdk import App, Environment 8 | from stacks.mre_plugins_stack import MrePluginsStack 9 | 10 | cdk_env = Environment(account=os.environ['CDK_DEFAULT_ACCOUNT'], 11 | region=os.environ['CDK_DEFAULT_REGION']) 12 | 13 | # new MyDevStack(app, 'dev', { 14 | # env: { 15 | # account: process.env.CDK_DEFAULT_ACCOUNT, 16 | # region: process.env.CDK_DEFAULT_REGION 17 | # }}); 18 | 19 | app = App() 20 | MrePluginsStack(app, "aws-mre-plugin-samples", env=cdk_env) 21 | 22 | app.synth() 23 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/cdk/cdk.context.json: -------------------------------------------------------------------------------- 1 | { 2 | "Plugins": [ 3 | "SegmentBySceneChange", 4 | "DetectTennisScoreBoxData", 5 | "DetectCameraScene", 6 | "LabelTennisScore", 7 | "DetectAudioPeaks", 8 | "SegmentByKeyMoment", 9 | "LabelBasic", 10 | "OptimizePassThrough", 11 | "SegmentPassThrough100", 12 | "LabelPassThrough", 13 | "DetectPassThrough100" 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/cdk/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/cdk/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk_nag==2.13.6 3 | constructs>=10.0.0 4 | boto3<2.0.0 5 | urllib3 6 | requests 7 | requests_aws4auth 8 | aws-cdk.aws_lambda_python_alpha -------------------------------------------------------------------------------- /samples/source/mre-plugin-samples/cdk/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-plugin-samples/cdk/stacks/__init__.py -------------------------------------------------------------------------------- /samples/source/mre-profile-samples/audit-pass-through-plugins/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "Optimizer": { 3 | "Configuration": {}, 4 | "Name": "OptimizePassThrough" 5 | }, 6 | "ProcessingFrameRate": 10, 7 | "ChunkSize": 10, 8 | "MaxSegmentLengthSeconds": 10, 9 | "Classifier": { 10 | "Configuration": { 11 | "chunk_to_segment_ratio": "0.5" 12 | }, 13 | "Name": "SegmentPassThrough100" 14 | }, 15 | "Labeler": { 16 | "Configuration": {}, 17 | "Name": "LabelPassThrough" 18 | }, 19 | "Featurers": [ 20 | { 21 | "Configuration": {}, 22 | "IsPriorityForReplay": true, 23 | "Name": "DetectPassThrough100" 24 | } 25 | ], 26 | "ContentGroups": [ 27 | "All" 28 | ], 29 | "Name": "AuditPassThroughPlugins" 30 | } -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/harvester_config_template.py: -------------------------------------------------------------------------------- 1 | EC2_INSTANCE_TYPE="" 2 | SUBNET_ID="" 3 | SECURITY_GROUPS_IDS="" 4 | MRE_REGION="" 5 | SQS_QUEUE_URL="" 6 | SQS_WAIT_TIME_SECS="" 7 | API_KEY="" 8 | CHUNK_SIZE="" 9 | DESTINATION_S3_BUCKET="" 10 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | #!/usr/bin/env python3 5 | from aws_cdk import App, Aspects 6 | from stacks.chaliceapp import ChaliceApp 7 | from cdk_nag import AwsSolutionsChecks 8 | 9 | app = App() 10 | ChaliceApp(app, 'aws-mre-samples-hls-harvester') 11 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 12 | 13 | app.synth() 14 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/samples/source/mre-video-ingestion-samples/HLS_Harvester/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "aws-mre-samples-hls-harvester" 4 | } 5 | -------------------------------------------------------------------------------- /samples/source/mre-video-ingestion-samples/HLS_Harvester/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | urllib3 4 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-contentgroup') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-contentgroup-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/contentgroup/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-custompriorities') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-custom-priorities-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/runtime/chalicelib/apischema/update_custom_priorities_engine.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "update_custom_priorities_engine", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Description": { 9 | "$id": "#/properties/Description", 10 | "type": "string", 11 | "title": "The Description Schema", 12 | "pattern": "^(.*)$" 13 | }, 14 | "EndpointSsmParam": { 15 | "$id": "#/properties/EndpointSsmParam", 16 | "type": "string", 17 | "title": "The EndpointSsmParam Schema" 18 | }, 19 | "SecretsManagerApiKeyArn": { 20 | "$id": "#/properties/SecretsManagerApiKeyArn", 21 | "type": "string", 22 | "title": "The SecretsManagerApiKeyArn Schema" 23 | } 24 | }, 25 | "additionalProperties": false 26 | } -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/runtime/chalicelib/apischema/update_status.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "update_status", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Enabled": { 9 | "$id": "#/properties/Enabled", 10 | "type": "boolean", 11 | "title": "The Enabled Schema", 12 | "default": true, 13 | "examples": [ 14 | true, 15 | false 16 | ] 17 | } 18 | }, 19 | "additionalProperties": false, 20 | "required": [ 21 | "Enabled" 22 | ] 23 | } -------------------------------------------------------------------------------- /source/api/controlplane/custompriorities/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 -------------------------------------------------------------------------------- /source/api/controlplane/event/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-event') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/event/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/event/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/event/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/event/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/event/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-event-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/event/runtime/chalicelib/Schedule.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | from dataclasses import dataclass, field 5 | 6 | @dataclass 7 | class Schedule: 8 | schedule_name: str 9 | event_name: str 10 | program_name: str 11 | event_start_time: str 12 | is_vod_event: bool 13 | bootstrap_time_in_mins: float 14 | event_duration_in_mins: float 15 | resource_arn: str 16 | execution_role: str 17 | input_payload: str 18 | stop_channel: bool = field(default=False) 19 | schedule_name_prefix: str = field(default="") 20 | 21 | -------------------------------------------------------------------------------- /source/api/controlplane/event/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/controlplane/model/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-model') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/model/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/model/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/model/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/model/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/model/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-model-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/model/runtime/chalicelib/apischema/update_status.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "update_status", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Enabled": { 9 | "$id": "#/properties/Enabled", 10 | "type": "boolean", 11 | "title": "The Enabled Schema", 12 | "default": true, 13 | "examples": [ 14 | true, 15 | false 16 | ] 17 | } 18 | }, 19 | "additionalProperties": false, 20 | "required": [ 21 | "Enabled" 22 | ] 23 | } -------------------------------------------------------------------------------- /source/api/controlplane/model/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-plugin') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-plugin-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/plugin/runtime/chalicelib/apischema/update_status.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "update_status", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Enabled": { 9 | "$id": "#/properties/Enabled", 10 | "type": "boolean", 11 | "title": "The Enabled Schema", 12 | "default": true, 13 | "examples": [ 14 | true, 15 | false 16 | ] 17 | } 18 | }, 19 | "additionalProperties": false, 20 | "required": [ 21 | "Enabled" 22 | ] 23 | } -------------------------------------------------------------------------------- /source/api/controlplane/plugin/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-profile') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-profile-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/profile/runtime/chalicelib/apischema/update_status.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "update_status", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Enabled": { 9 | "$id": "#/properties/Enabled", 10 | "type": "boolean", 11 | "title": "The Enabled Schema", 12 | "default": true, 13 | "examples": [ 14 | true, 15 | false 16 | ] 17 | } 18 | }, 19 | "additionalProperties": false, 20 | "required": [ 21 | "Enabled" 22 | ] 23 | } -------------------------------------------------------------------------------- /source/api/controlplane/profile/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/controlplane/program/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-program') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/program/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/program/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/program/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/program/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/program/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-program-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/program/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-replay') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | constructs>=10.0.0 3 | chalice[cdkv2] 4 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/api/controlplane/replay/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-replay-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/replay/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | rsa==4.7.2 5 | -------------------------------------------------------------------------------- /source/api/controlplane/system/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-system') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/system/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/system/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/system/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/system/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/system/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-system-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/system/runtime/chalicelib/apischema/put_system_configuration.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "put_system_configuration", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Name": { 9 | "$id": "#/properties/Name", 10 | "type": "string", 11 | "title": "The Name Schema" 12 | }, 13 | "Value": { 14 | "$id": "#/properties/Value", 15 | "type": ["array", "boolean", "integer", "number", "object", "string"], 16 | "title": "The Value Schema" 17 | } 18 | }, 19 | "additionalProperties": false, 20 | "required": [ 21 | "Name", 22 | "Value" 23 | ] 24 | } -------------------------------------------------------------------------------- /source/api/controlplane/system/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | ChaliceApp(app, 'aws-mre-controlplane-workflow') 12 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | app.synth() 15 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 4 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-workflow-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/controlplane/workflow/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | -------------------------------------------------------------------------------- /source/api/dataplane/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | 3 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | from aws_cdk import App, Tags, Aspects 7 | from stacks.chaliceapp import ChaliceApp 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | stack = ChaliceApp(app, 'aws-mre-dataplane') 12 | Aspects.of(stack).add(AwsSolutionsChecks(verbose=True)) 13 | 14 | # Add a tag to all constructs in the stack 15 | Tags.of(stack).add("Project", "AWS-MRE") 16 | Tags.of(stack).add("System", "DataPlaneAPI") 17 | 18 | app.synth() 19 | -------------------------------------------------------------------------------- /source/api/dataplane/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/api/dataplane/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | aws-cdk.aws-lambda-python-alpha>=2.24.1a0,<3.0 3 | chalice[cdkv2] 4 | cdk-nag==2.28.159 5 | -------------------------------------------------------------------------------- /source/api/dataplane/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/api/dataplane/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "aws-mre-dataplane-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "api", 7 | "lambda_functions": { 8 | "api_handler": { 9 | "environment_variables": { 10 | "APP_TABLE_NAME": "" 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/chalicelib/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import os 5 | import json 6 | from decimal import Decimal 7 | 8 | 9 | def load_api_schema(): 10 | api_schema = {} 11 | schema_dir = os.path.dirname(__file__) + "/apischema/" 12 | 13 | for file in os.listdir(schema_dir): 14 | with open(schema_dir + file) as schema_file: 15 | schema = json.load(schema_file) 16 | schema_title = schema["title"] 17 | api_schema[schema_title] = schema 18 | print(f"Loaded schema: {schema_title}") 19 | 20 | return api_schema 21 | 22 | def replace_decimals(obj): 23 | if isinstance(obj, list): 24 | return [replace_decimals(o) for o in obj] 25 | elif isinstance(obj, dict): 26 | return {k: replace_decimals(v) for k, v in obj.items()} 27 | elif isinstance(obj, Decimal): 28 | return int(obj) if obj % 1 == 0 else float(obj) 29 | else: 30 | return obj 31 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/chalicelib/apischema/get_segments_for_clip_generation.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "$id": "http://json-schema.org/draft-07/schema#", 4 | "title": "get_segments_for_clip_generation", 5 | "type": "object", 6 | "definitions": {}, 7 | "properties": { 8 | "Program": { 9 | "$id": "#/properties/Program", 10 | "type": "string", 11 | "title": "The Program Schema", 12 | "pattern": "^(.*)$" 13 | }, 14 | "Event": { 15 | "$id": "#/properties/Event", 16 | "type": "string", 17 | "title": "The Event Schema", 18 | "pattern": "^(.*)$" 19 | }, 20 | "Classifier": { 21 | "$id": "#/properties/Classifier", 22 | "type": "string", 23 | "title": "The Classifier Schema", 24 | "pattern": "^(.*)$" 25 | } 26 | }, 27 | "additionalProperties": false, 28 | "required": [ 29 | "Program", 30 | "Event", 31 | "Classifier" 32 | ] 33 | } -------------------------------------------------------------------------------- /source/api/dataplane/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | jsonschema==3.2.0 4 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/vendor/_pyrsistent_version.py: -------------------------------------------------------------------------------- 1 | __version__ = '0.17.3' 2 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/vendor/pyrsistent-0.17.3.dist-info/LICENCE.mit: -------------------------------------------------------------------------------- 1 | Copyright (c) 2019 Tobias Gustafsson 2 | 3 | Permission is hereby granted, free of charge, to any person 4 | obtaining a copy of this software and associated documentation 5 | files (the "Software"), to deal in the Software without 6 | restriction, including without limitation the rights to use, 7 | copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | copies of the Software, and to permit persons to whom the 9 | Software is furnished to do so, subject to the following 10 | conditions: 11 | 12 | The above copyright notice and this permission notice shall be 13 | included in all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 16 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 17 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 18 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 19 | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 20 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 21 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 22 | OTHER DEALINGS IN THE SOFTWARE. -------------------------------------------------------------------------------- /source/api/dataplane/runtime/vendor/pyrsistent-0.17.3.dist-info/WHEEL: -------------------------------------------------------------------------------- 1 | Wheel-Version: 1.0 2 | Generator: bdist_wheel (0.36.2) 3 | Root-Is-Purelib: false 4 | Tag: cp38-cp38-linux_x86_64 5 | 6 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/vendor/pyrsistent-0.17.3.dist-info/top_level.txt: -------------------------------------------------------------------------------- 1 | _pyrsistent_version 2 | pvectorc 3 | pyrsistent 4 | -------------------------------------------------------------------------------- /source/api/dataplane/runtime/vendor/pyrsistent/py.typed: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/api/dataplane/runtime/vendor/pyrsistent/py.typed -------------------------------------------------------------------------------- /source/backend/caching/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.chaliceapp import ChaliceApp 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ChaliceApp(app, 'aws-mre-segment-caching', description="MRE Segment Caching stack") 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | app.synth() 10 | -------------------------------------------------------------------------------- /source/backend/caching/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/caching/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/backend/caching/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/caching/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/caching/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/backend/caching/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | boto3<2.0.0 2 | -------------------------------------------------------------------------------- /source/backend/clipgeneration/Readme.md: -------------------------------------------------------------------------------- 1 | self.mre_media_output_bucket.bucket_name 2 | 3 | event_bus = events.EventBus.from_event_bus_arn(this, "ImportedEventBus", "arn:aws:events:us-east-1:111111111:event-bus/my-event-bus") 4 | 5 | layers=[self.mre_workflow_helper_layer, 6 | self.mre_plugin_helper_layer, 7 | self.timecode_layer 8 | ] 9 | 10 | 11 | 12 | self.timecode_layer 13 | 14 | 15 | self.mre_edlgen_events_rule.node.add_dependency(self.eb_event_bus) -------------------------------------------------------------------------------- /source/backend/clipgeneration/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.ClipGenStack import ClipGenStack 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ClipGenStack(app, 'aws-mre-clip-generation', description="MRE Clip Generation Lambda Functions stack") 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | 10 | app.synth() 11 | -------------------------------------------------------------------------------- /source/backend/clipgeneration/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/clipgeneration/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/backend/clipgeneration/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/clipgeneration/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/clipgeneration/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/backend/clipgeneration/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | boto3<2.0.0 2 | -------------------------------------------------------------------------------- /source/backend/data_export/Readme.md: -------------------------------------------------------------------------------- 1 | self.mre_media_output_bucket.bucket_name 2 | 3 | event_bus = events.EventBus.from_event_bus_arn(this, "ImportedEventBus", "arn:aws:events:us-east-1:111111111:event-bus/my-event-bus") 4 | 5 | layers=[self.mre_workflow_helper_layer, 6 | self.mre_plugin_helper_layer, 7 | self.timecode_layer 8 | ] 9 | 10 | 11 | 12 | self.timecode_layer 13 | 14 | 15 | self.mre_edlgen_events_rule.node.add_dependency(self.eb_event_bus) -------------------------------------------------------------------------------- /source/backend/data_export/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.DataExporter import MreDataExporter 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | MreDataExporter(app, 'aws-mre-data-exporter', description="MRE Data Export Lambda Functions stack") 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | 10 | app.synth() 11 | -------------------------------------------------------------------------------- /source/backend/data_export/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/data_export/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/backend/data_export/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/data_export/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/data_export/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -------------------------------------------------------------------------------- /source/backend/data_export/runtime/lambda/shared/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/backend/event-life-cycle/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.chaliceapp import ChaliceApp 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ChaliceApp(app, 'aws-mre-event-life-cycle') 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | 10 | app.synth() 11 | -------------------------------------------------------------------------------- /source/backend/event-life-cycle/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/event-life-cycle/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 3 | -------------------------------------------------------------------------------- /source/backend/event-life-cycle/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/event-life-cycle/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/event-life-cycle/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/lambda/requirements.txt 3 | 4 | -------------------------------------------------------------------------------- /source/backend/event-life-cycle/runtime/lambda/requirements.txt: -------------------------------------------------------------------------------- 1 | boto3==1.26.54 2 | -------------------------------------------------------------------------------- /source/backend/replay/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.ReplayStack import ReplayStack 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ReplayStack(app, 'aws-mre-replay-handler', description="MRE Replay Lambda Functions stack") 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | 10 | app.synth() 11 | -------------------------------------------------------------------------------- /source/backend/replay/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/replay/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/backend/replay/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/replay/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/replay/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt -------------------------------------------------------------------------------- /source/backend/replay/runtime/shared/GetReplayResults.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import gzip 5 | import json 6 | import boto3 7 | from boto3.dynamodb.conditions import Key 8 | 9 | #TODO: Replace the following Values as per your Env 10 | REPLAY_RESULTS_TABLE_NAME = "" 11 | PK_VALUE = "" 12 | 13 | 14 | ddb_resource = boto3.resource("dynamodb") 15 | replay_results_table = ddb_resource.Table(REPLAY_RESULTS_TABLE_NAME) 16 | replay_results_query = replay_results_table.query( 17 | KeyConditionExpression=Key("ProgramEventReplayId").eq(PK_VALUE) 18 | ) 19 | replay_results = gzip.decompress(bytes(replay_results_query['Items'][0]['ReplayResults'])).decode('utf-8') 20 | results = json.loads(replay_results) 21 | print(json.dumps([x for x in results])) -------------------------------------------------------------------------------- /source/backend/replay/runtime/shared/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | -------------------------------------------------------------------------------- /source/backend/workflow_trigger/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.chaliceapp import ChaliceApp 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ChaliceApp(app, 'aws-mre-workflow-trigger') 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | app.synth() 10 | -------------------------------------------------------------------------------- /source/backend/workflow_trigger/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/backend/workflow_trigger/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/backend/workflow_trigger/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/backend/workflow_trigger/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/backend/workflow_trigger/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -------------------------------------------------------------------------------- /source/frontend/amplify.yml: -------------------------------------------------------------------------------- 1 | version: 1 2 | applications: 3 | - frontend: 4 | phases: 5 | preBuild: 6 | commands: 7 | - curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.5/install.sh | bash 8 | - . ~/.nvm/nvm.sh 9 | - nvm install 20.10.0 10 | - nvm use 20.10.0 11 | - npm install --legacy-peer-deps 12 | build: 13 | commands: 14 | - INLINE_RUNTIME_CHUNK=false npm run build 15 | artifacts: 16 | baseDirectory: build 17 | files: 18 | - '**/*' 19 | cache: 20 | paths: 21 | - node_modules/**/* 22 | -------------------------------------------------------------------------------- /source/frontend/cdk/app.py: -------------------------------------------------------------------------------- 1 | ''' 2 | Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | SPDX-License-Identifier: Apache-2.0 4 | ''' 5 | 6 | from aws_cdk import App, Aspects 7 | from stacks.mre_frontend_stack import MreFrontendStack 8 | from cdk_nag import AwsSolutionsChecks 9 | 10 | app = App() 11 | 12 | MreFrontendStack(app, "mre-frontend-stack") 13 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 14 | 15 | app.synth() -------------------------------------------------------------------------------- /source/frontend/cdk/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/frontend/cdk/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | aws-cdk.aws-amplify-alpha>=2.24.1a0,<3.0 3 | constructs>=10.0.0 4 | boto3<2.0.0 5 | cdk-nag==2.28.159 6 | 7 | -------------------------------------------------------------------------------- /source/frontend/cdk/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/cdk/stacks/__init__.py -------------------------------------------------------------------------------- /source/frontend/env.template: -------------------------------------------------------------------------------- 1 | REACT_APP_REGION= 2 | REACT_APP_BASE_API= 3 | REACT_APP_DATA_PLANE_API= 4 | REACT_APP_USER_POOL_ID= 5 | REACT_APP_APP_CLIENT_ID= 6 | REACT_APP_IDENTITY_POOL_ID= 7 | REACT_APP_CLOUDFRONT_DOMAIN_NAME= -------------------------------------------------------------------------------- /source/frontend/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/public/favicon.ico -------------------------------------------------------------------------------- /source/frontend/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | } 10 | ], 11 | "start_url": "./index.html", 12 | "display": "standalone", 13 | "theme_color": "#000000", 14 | "background_color": "#ffffff" 15 | } 16 | -------------------------------------------------------------------------------- /source/frontend/src/App.css: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | @import 'assets/fonts/fonts.css'; 7 | 8 | html, body { 9 | width: 100%; 10 | height: 100%; 11 | min-height: 100%; 12 | margin: 0px; 13 | box-sizing: border-box; 14 | overflow-x: hidden; 15 | } 16 | 17 | div { 18 | display: block; 19 | } 20 | 21 | #root { 22 | height: 100%; 23 | width: 100%; 24 | } -------------------------------------------------------------------------------- /source/frontend/src/assets/TransitionsImg/BlackFadeInFadeOut.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/TransitionsImg/BlackFadeInFadeOut.png -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazon-ember-medium-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazon-ember-medium-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazon-ember-medium-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazon-ember-medium-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazon-ember-mediumitalic-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_bd-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_bd-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_bd-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_bd-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_bdit-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_bdit-webfont.ttf -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_bdit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_bdit-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_bdit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_bdit-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_he-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_he-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_he-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_he-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_heit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_heit-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_heit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_heit-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_lt-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_lt-webfont.ttf -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_lt-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_lt-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_lt-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_lt-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_ltit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_ltit-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_ltit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_ltit-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_rg-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_rg-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_rg-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_rg-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_rgit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_rgit-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_rgit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_rgit-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_th-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_th-webfont.ttf -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_th-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_th-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_th-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_th-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_thit-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_thit-webfont.woff -------------------------------------------------------------------------------- /source/frontend/src/assets/fonts/amazonember_thit-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/fonts/amazonember_thit-webfont.woff2 -------------------------------------------------------------------------------- /source/frontend/src/assets/videos/FadeInOutSample.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/frontend/src/assets/videos/FadeInOutSample.mp4 -------------------------------------------------------------------------------- /source/frontend/src/common/Copyright.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from 'react'; 7 | import Typography from "@material-ui/core/Typography"; 8 | import Box from "@material-ui/core/Box"; 9 | 10 | export const Copyright = () => { 11 | return ( 12 | 13 | 14 | {'Copyright © '} 15 | {new Date().getFullYear()} 16 | {' Amazon Web Services, Inc. or its affiliates. All rights reserved'} 17 | 18 | 19 | ); 20 | }; -------------------------------------------------------------------------------- /source/frontend/src/common/routes/AuthenticatedRoute.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from "react"; 7 | import { Route, Navigate, useLocation } from "react-router-dom"; 8 | 9 | import {useSessionContext} from "../../contexts/SessionContext"; 10 | 11 | export const AuthenticatedRoute = ({ component: Component, ...rest }) => { 12 | const {isAuthenticated} = useSessionContext(); 13 | const location = useLocation() 14 | return isAuthenticated === true 15 | ? 16 | : 21 | }; 22 | 23 | -------------------------------------------------------------------------------- /source/frontend/src/common/routes/UnauthenticatedRoute.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from "react"; 7 | import { Route, Navigate } from "react-router-dom"; 8 | 9 | import {useSessionContext} from "../../contexts/SessionContext"; 10 | 11 | export const UnauthenticatedRoute = ({ component: Component, ...rest }) => { 12 | const {isAuthenticated} = useSessionContext(); 13 | return isAuthenticated === false 14 | ? 15 | : 19 | }; -------------------------------------------------------------------------------- /source/frontend/src/common/utils/withRouter.js: -------------------------------------------------------------------------------- 1 | import { 2 | useLocation, 3 | useNavigate, 4 | useParams, 5 | } from "react-router-dom"; 6 | 7 | export function withRouter(Component) { 8 | function ComponentWithRouterProp(props) { 9 | let location = useLocation(); 10 | let navigate = useNavigate(); 11 | let params = useParams(); 12 | return ( 13 | 17 | ); 18 | } 19 | 20 | return ComponentWithRouterProp; 21 | } -------------------------------------------------------------------------------- /source/frontend/src/components/ClipPreviewFeedback/ClipPlaceholder.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from 'react'; 7 | import _ from "lodash"; 8 | import Grid from "@material-ui/core/Grid"; 9 | import { 10 | Typography 11 | } from "@material-ui/core"; 12 | 13 | 14 | export const ClipPlaceholder = (props) => { 15 | 16 | return ( 17 | 18 | 19 | 20 | 21 | {props.Title} 22 | 23 | 24 | 25 | { 26 | 27 | 28 | {props.Message} 29 | 30 | 31 | } 32 | 33 | 34 | ); 35 | 36 | 37 | }; -------------------------------------------------------------------------------- /source/frontend/src/components/Footer/Footer.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from 'react'; 7 | import { makeStyles } from '@material-ui/core/styles'; 8 | import {Copyright} from '../../common/Copyright'; 9 | import {Box} from "@material-ui/core"; 10 | 11 | const useStyles = makeStyles((theme) => ({ 12 | footer: { 13 | padding: theme.spacing(1, 1), 14 | marginTop: 'auto', 15 | color: theme.palette.layout.contrastText, 16 | backgroundColor: theme.palette.layout.main, 17 | position: 'fixed', 18 | bottom: 0, 19 | left: 0, 20 | width: '100%', 21 | zIndex: 1 22 | }, 23 | })); 24 | 25 | export const Footer = () => { 26 | const classes = useStyles(); 27 | 28 | return ( 29 |
30 | 31 | 32 | 33 |
34 | ); 35 | }; -------------------------------------------------------------------------------- /source/frontend/src/components/Layouts/DemoContainer.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from 'react'; 7 | import clsx from 'clsx'; 8 | 9 | import {makeStyles} from "@material-ui/core/styles"; 10 | 11 | const useStyles = makeStyles((theme) => ({ 12 | demoContainer: { 13 | display: 'flex', 14 | flexDirection: 'column', 15 | height: '100%', 16 | } 17 | })); 18 | 19 | export const DemoContainer = (props) => { 20 | const classes = useStyles(); 21 | const {bgType, className, ...rest} = props; 22 | 23 | return ( 24 | <> 25 |
26 | {props.children} 27 |
28 | 29 | ) 30 | }; 31 | -------------------------------------------------------------------------------- /source/frontend/src/config.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | export default { 7 | "APP_TITLE": "MRE", 8 | "s3": { 9 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 10 | "BUCKET": "" 11 | }, 12 | "apiGateway": { 13 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 14 | "REACT_APP_BASE_API": process.env.REACT_APP_BASE_API, 15 | "REACT_APP_DATA_PLANE_API": process.env.REACT_APP_DATA_PLANE_API 16 | }, 17 | "cognito": { 18 | "REACT_APP_REGION": process.env.REACT_APP_REGION, 19 | "REACT_APP_USER_POOL_ID": process.env.REACT_APP_USER_POOL_ID, 20 | "REACT_APP_APP_CLIENT_ID": process.env.REACT_APP_APP_CLIENT_ID, 21 | "REACT_APP_IDENTITY_POOL_ID": process.env.REACT_APP_IDENTITY_POOL_ID 22 | }, 23 | "cloudfront":{ 24 | "REACT_APP_CLOUDFRONT_DOMAIN_NAME": process.env.REACT_APP_CLOUDFRONT_DOMAIN_NAME 25 | } 26 | }; 27 | -------------------------------------------------------------------------------- /source/frontend/src/containers/NotFound/NotFound.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import React from "react"; 7 | 8 | //@todo spice it up with gopher graphic 9 | export default () => { 10 | return ( 11 |
12 |

Sorry, page not found!

13 |
14 | ); 15 | } 16 | -------------------------------------------------------------------------------- /source/frontend/src/contexts/SessionContext.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | import { useContext, createContext } from "react"; 7 | 8 | export const SessionContext = createContext(null); 9 | 10 | export function useSessionContext() { 11 | return useContext(SessionContext); 12 | } -------------------------------------------------------------------------------- /source/frontend/src/index.css: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | body { 7 | margin: 0; 8 | -webkit-font-smoothing: antialiased; 9 | -moz-osx-font-smoothing: grayscale; 10 | } -------------------------------------------------------------------------------- /source/gateway/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.chaliceapp import ChaliceApp 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | ChaliceApp(app, 'aws-mre-gateway', description="MRE Gateway API reverse proxy stack. Implements IAM based Auth and JWT token based Auth based routes.") 8 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 9 | app.synth() 10 | -------------------------------------------------------------------------------- /source/gateway/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/gateway/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | chalice[cdkv2] 3 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/gateway/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/gateway/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/gateway/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -r runtime/requirements.txt 3 | -------------------------------------------------------------------------------- /source/gateway/runtime/.chalice/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0", 3 | "app_name": "mre-gateway-api", 4 | "stages": { 5 | "dev": { 6 | "api_gateway_stage": "beta" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /source/gateway/runtime/requirements.txt: -------------------------------------------------------------------------------- 1 | chalice 2 | boto3<2.0.0 3 | requests 4 | requests-aws4auth==1.1.1 5 | PyJWT==2.4.0 -------------------------------------------------------------------------------- /source/layers/MediaReplayEnginePluginHelper/MediaReplayEnginePluginHelper.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/layers/MediaReplayEnginePluginHelper/MediaReplayEnginePluginHelper.zip -------------------------------------------------------------------------------- /source/layers/MediaReplayEngineWorkflowHelper/MediaReplayEngineWorkflowHelper.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/layers/MediaReplayEngineWorkflowHelper/MediaReplayEngineWorkflowHelper.zip -------------------------------------------------------------------------------- /source/layers/ffmpeg/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/layers/ffmpeg/.gitkeep -------------------------------------------------------------------------------- /source/layers/ffprobe/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/layers/ffprobe/.gitkeep -------------------------------------------------------------------------------- /source/layers/timecode/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/layers/timecode/.gitkeep -------------------------------------------------------------------------------- /source/lib/MediaReplayEnginePluginHelper/README.md: -------------------------------------------------------------------------------- 1 | # Media Replay Engine Plugin Helper 2 | 3 | This package serves as a helper library to aid the development of custom plugins for the Media Replay Engine. 4 | 5 | Contains classes for the below needs: 6 | 7 | * Dataplane interaction 8 | * Plugin utility functions 9 | * Output formatting 10 | * Custom Exception 11 | 12 | 13 | # Usage 14 | 15 | Use the python `import` command. For example: 16 | 17 | ``` 18 | from MediaReplayEnginePluginHelper import DataPlane 19 | from MediaReplayEnginePluginHelper import PluginHelper 20 | from MediaReplayEnginePluginHelper import OutputHelper 21 | from MediaReplayEnginePluginHelper import MREExecutionError 22 | ``` 23 | -------------------------------------------------------------------------------- /source/lib/MediaReplayEnginePluginHelper/setup.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import setuptools 5 | 6 | with open("README.md", "r") as fh: 7 | long_description = fh.read() 8 | 9 | setuptools.setup( 10 | name="Media Replay Engine Plugin Helper", 11 | version="1.0.0", 12 | author="Aravindharaj Rajendran", 13 | author_email="redacted@example.com", 14 | description="Helper library to aid the development of custom plugins for the Media Replay Engine", 15 | long_description=long_description, 16 | long_description_content_type="text/markdown", 17 | url="https://github.com/awslabs/aws-media-replay-engine", 18 | packages=setuptools.find_packages(), 19 | install_requires=[ 20 | 'urllib3<2', 21 | 'requests', 22 | 'requests-aws4auth' 23 | ], 24 | classifiers=[ 25 | "Programming Language :: Python :: 3", 26 | "License :: Other/Proprietary License", 27 | "Operating System :: OS Independent", 28 | ], 29 | ) 30 | -------------------------------------------------------------------------------- /source/lib/MediaReplayEngineWorkflowHelper/README.md: -------------------------------------------------------------------------------- 1 | # Media Replay Engine Workflow Helper 2 | 3 | This package serves as a helper library used by the Media Replay Engine internal lambda functions to interact with the control plane. 4 | 5 | 6 | # Usage 7 | 8 | Use the python `import` command. For example: 9 | 10 | ``` 11 | from MediaReplayEngineWorkflowHelper import ControlPlane 12 | ``` 13 | -------------------------------------------------------------------------------- /source/lib/MediaReplayEngineWorkflowHelper/setup.py: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | import setuptools 5 | 6 | with open("README.md", "r") as fh: 7 | long_description = fh.read() 8 | 9 | setuptools.setup( 10 | name="Media Replay Engine Workflow Helper", 11 | version="1.0.0", 12 | author="Aravindharaj Rajendran", 13 | author_email="redacted@example.com", 14 | description="Helper library used by the Media Replay Engine internal lambda functions to interact with the control plane", 15 | long_description=long_description, 16 | long_description_content_type="text/markdown", 17 | url="https://github.com/awslabs/aws-media-replay-engine", 18 | packages=setuptools.find_packages(), 19 | install_requires=[ 20 | 'urllib3<2', 21 | 'requests', 22 | 'requests-aws4auth' 23 | ], 24 | classifiers=[ 25 | "Programming Language :: Python :: 3", 26 | "License :: Other/Proprietary License", 27 | "Operating System :: OS Independent", 28 | ], 29 | ) 30 | -------------------------------------------------------------------------------- /source/shared/infrastructure/app.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | from aws_cdk import App, Aspects 3 | from stacks.sharedResources import MreSharedResources 4 | from cdk_nag import AwsSolutionsChecks 5 | 6 | app = App() 7 | 8 | MreSharedResources(app, 'aws-mre-shared-resources', description="MRE Shared resources stack") 9 | Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 10 | 11 | app.synth() 12 | -------------------------------------------------------------------------------- /source/shared/infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py" 3 | } 4 | -------------------------------------------------------------------------------- /source/shared/infrastructure/helpers/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/shared/infrastructure/helpers/__init__.py -------------------------------------------------------------------------------- /source/shared/infrastructure/helpers/constants.py: -------------------------------------------------------------------------------- 1 | FRAMEWORK_VERSION = "%%FRAMEWORK_VERSION%%" 2 | PLUGIN_NAME_INDEX = "Name-index" 3 | PLUGIN_VERSION_INDEX = "Version-index" 4 | MODEL_NAME_INDEX = "Name-index" 5 | MODEL_VERSION_INDEX = "Version-index" 6 | EVENT_CHANNEL_INDEX = "Channel-index" 7 | EVENT_PROGRAMID_INDEX = "ProgramId-index" 8 | EVENT_CONTENT_GROUP_INDEX = "ContentGroup-index" 9 | EVENT_PAGINATION_INDEX = "Pagination-index" 10 | EVENT_PROGRAM_INDEX = "Program-index" 11 | EVENT_BYOB_NAME_INDEX= "SourceVideoBucket-Name-index" 12 | -------------------------------------------------------------------------------- /source/shared/infrastructure/requirements.txt: -------------------------------------------------------------------------------- 1 | aws-cdk-lib>=2.24.1,<3.0 2 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /source/shared/infrastructure/stacks/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/source/shared/infrastructure/stacks/__init__.py -------------------------------------------------------------------------------- /source/shared/requirements.txt: -------------------------------------------------------------------------------- 1 | -r infrastructure/requirements.txt 2 | -------------------------------------------------------------------------------- /tests/.dockerignore: -------------------------------------------------------------------------------- 1 | .pytest_cache/* 2 | .venv 3 | Infrastructure/cdk.out 4 | -------------------------------------------------------------------------------- /tests/.gitignore: -------------------------------------------------------------------------------- 1 | test_report* 2 | .pytest_cache/* 3 | .venv 4 | **/__pycache__ 5 | **/.pytest_cache 6 | *.swp 7 | *__pycache__/ 8 | .pytest_cache 9 | *.egg-info 10 | chalice.out 11 | **/.chalice/deployments/ 12 | **/.chalice/venv/ 13 | venv/ 14 | .aws-sam 15 | .idea/ 16 | .vscode 17 | *.DS_Store 18 | .env 19 | assets 20 | Infrastructure/cdk.out 21 | creds.sh 22 | *.html 23 | docker* 24 | Dockerfile* -------------------------------------------------------------------------------- /tests/Infrastructure/app.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | #!/usr/bin/env python3 5 | import aws_cdk as cdk 6 | from stack import MreTestSuiteStack 7 | from cdk_nag import AwsSolutionsChecks 8 | 9 | app = cdk.App() 10 | apiStack = MreTestSuiteStack(app, "aws-mre-test-suite", env=cdk.Environment()) 11 | cdk.Aspects.of(app).add(AwsSolutionsChecks(verbose=True)) 12 | app.synth() 13 | -------------------------------------------------------------------------------- /tests/Infrastructure/cdk.json: -------------------------------------------------------------------------------- 1 | { 2 | "app": "python3 app.py", 3 | "watch": { 4 | "include": [ 5 | "**" 6 | ], 7 | "exclude": [ 8 | "README.md", 9 | "cdk*.json", 10 | "requirements*.txt", 11 | "source.bat", 12 | "**/__init__.py", 13 | "python/__pycache__", 14 | "tests" 15 | ] 16 | }, 17 | "context": { 18 | "@aws-cdk/aws-apigateway:usagePlanKeyOrderInsensitiveId": true, 19 | "@aws-cdk/core:stackRelativeExports": true, 20 | "@aws-cdk/aws-rds:lowercaseDbIdentifier": true, 21 | "@aws-cdk/aws-lambda:recognizeVersionProps": true, 22 | "@aws-cdk/aws-cloudfront:defaultSecurityPolicyTLSv1.2_2021": true, 23 | "@aws-cdk-containers/ecs-service-extensions:enableDefaultLogDriver": true, 24 | "@aws-cdk/aws-ec2:uniqueImdsv2TemplateName": true, 25 | "@aws-cdk/core:checkSecretUsage": true, 26 | "@aws-cdk/aws-iam:minimizePolicies": true, 27 | "@aws-cdk/core:target-partitions": [ 28 | "aws", 29 | "aws-cn" 30 | ] 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /tests/Infrastructure/sample_video/MRE-Sample.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/tests/Infrastructure/sample_video/MRE-Sample.mp4 -------------------------------------------------------------------------------- /tests/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/tests/__init__.py -------------------------------------------------------------------------------- /tests/core/Events/channel.py: -------------------------------------------------------------------------------- 1 | 2 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | # SPDX-License-Identifier: MIT-0import pytest 4 | 5 | 6 | import boto3 7 | from filelock import FileLock 8 | 9 | client = boto3.client('medialive') 10 | 11 | def start_channel(channel_id): 12 | print(channel_id) 13 | client.start_channel( 14 | ChannelId=channel_id 15 | ) 16 | 17 | def stop_channel(channel_id): 18 | client.stop_channel( 19 | ChannelId=channel_id 20 | ) 21 | 22 | def get_channel_by_destination_bucket(bucket_name: str): 23 | response = client.list_channels() 24 | for channel in response['Channels']: 25 | if 'Destinations' in channel: 26 | for destination in channel['Destinations']: 27 | if 'Settings' in destination: 28 | for setting in destination['Settings']: 29 | if bucket_name in setting['Url']: 30 | return channel['Id'] 31 | 32 | return "" 33 | -------------------------------------------------------------------------------- /tests/core/Events/config/EventPassThrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TS1", 3 | "Program": "Regression", 4 | "Description": "Event scheduled for Regression testing", 5 | "Channel": "", 6 | "ProgramId": "NA", 7 | "BootstrapTimeInMinutes": 3, 8 | "Profile": "", 9 | "ContentGroup": "All", 10 | "Start": "", 11 | "DurationMinutes": 2, 12 | "Archive": false, 13 | "GenerateOrigClips": true, 14 | "GenerateOptoClips": true, 15 | "TimecodeSource": "NOT_EMBEDDED", 16 | "StopMediaLiveChannel": true 17 | } -------------------------------------------------------------------------------- /tests/core/Events/config/LabelPassthrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-EventTest-LabelPassThrough", 3 | "Description": "A way to baseline framework latency with a trivial labeling task.", 4 | "Class": "Labeler", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:LabelPassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Events/config/OptimizePassThrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-EventTest-OptimizePassThrough", 3 | "Description": "A way to baseline framework latency with a trivial optimization task.", 4 | "Class": "Optimizer", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:OptimizePassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Events/config/PassThroughProfile.json: -------------------------------------------------------------------------------- 1 | { 2 | "Optimizer": { 3 | "Configuration": {}, 4 | "Name": "TestSuite-EventTest-OptimizePassThrough" 5 | }, 6 | "ProcessingFrameRate": 10, 7 | "ChunkSize": 10, 8 | "MaxSegmentLengthSeconds": 10, 9 | "Classifier": { 10 | "Configuration": { 11 | "chunk_to_segment_ratio": "0.5" 12 | }, 13 | "Name": "TestSuite-EventTest-SegmentPassThrough100" 14 | }, 15 | "Labeler": { 16 | "Configuration": {}, 17 | "Name": "TestSuite-EventTest-LabelPassThrough" 18 | }, 19 | "Featurers": [ 20 | { 21 | "Configuration": {}, 22 | "IsPriorityForReplay": true, 23 | "Name": "TestSuite-EventTest-DetectPassThrough100" 24 | } 25 | ], 26 | "ContentGroups": [ 27 | "All" 28 | ], 29 | "Name": "TestSuite-EventTestPassThroughProfile" 30 | } -------------------------------------------------------------------------------- /tests/core/Events/config/SegmentPassThrough100.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-EventTest-SegmentPassThrough100", 3 | "Description": "This plugin is used to test MRE in a simple way by creating segments for each chunk based on time.", 4 | "Class": "Classifier", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:SegmentPassThrough100:$LATEST", 11 | "Configuration": { 12 | "chunk_to_segment_ratio": "0.5" 13 | } 14 | } -------------------------------------------------------------------------------- /tests/core/Events/models/event_config.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | from dataclasses import dataclass, field 5 | 6 | @dataclass 7 | class EventConfig: 8 | GenerateOrigClips: bool = False 9 | GenerateOptoClips: bool = False 10 | FutureEvent: bool = False 11 | EventName: str = None 12 | 13 | 14 | 15 | @dataclass 16 | class MediaLiveEventConfig(EventConfig): 17 | Channel: str = None 18 | 19 | @dataclass 20 | class BYOBEventConfig(EventConfig): 21 | SourceVideoBucket: str = None 22 | -------------------------------------------------------------------------------- /tests/core/Models/config/invalid_end_point.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "InvalidEndpointModel", 3 | "Description": "Invalid Endpoint Model", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "Baseball" 7 | ], 8 | "Endpoint": "https" 9 | } -------------------------------------------------------------------------------- /tests/core/Models/config/invalid_plugin_class.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-InvalidPluginClassModel", 3 | "Description": "TestSuite Invalid Plugin class Model", 4 | "PluginClass": "RandomPluginClass", 5 | "ContentGroups": [ 6 | "Tennis" 7 | ], 8 | "Endpoint": "Test" 9 | } -------------------------------------------------------------------------------- /tests/core/Models/config/no_end_point.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-NoEndpointModel", 3 | "Description": "TestSuite No Endpoint Model", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "Tennis" 7 | ] 8 | } -------------------------------------------------------------------------------- /tests/core/Models/config/valid_end_point.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ValidEndpointModel", 3 | "Description": "TestSuite Valid Endpoint Model", 4 | "PluginClass": "Featurer", 5 | "ContentGroups": [ 6 | "Tennis" 7 | ], 8 | "Endpoint": "asasd 2" 9 | } -------------------------------------------------------------------------------- /tests/core/Plugins/config/LabelPassthrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ModelTest-LabelPassThrough", 3 | "Description": "A way to baseline framework latency with a trivial labeling task.", 4 | "Class": "Labeler", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:LabelPassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Plugins/config/OptimizePassThrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ModelTest-OptimizePassThrough", 3 | "Description": "A way to baseline framework latency with a trivial optimization task.", 4 | "Class": "Optimizer", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:OptimizePassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Plugins/config/SegmentPassThrough100.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ModelTest-SegmentPassThrough100", 3 | "Description": "This plugin is used to test MRE in a simple way by creating segments for each chunk based on time.", 4 | "Class": "Classifier", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:SegmentPassThrough100:$LATEST", 11 | "Configuration": { 12 | "chunk_to_segment_ratio": "0.5" 13 | } 14 | } -------------------------------------------------------------------------------- /tests/core/Profiles/config/LabelPassthrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ProfileTest-LabelPassThrough", 3 | "Description": "A way to baseline framework latency with a trivial labeling task.", 4 | "Class": "Labeler", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:LabelPassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Profiles/config/OptimizePassThrough.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ProfileTest-OptimizePassThrough", 3 | "Description": "A way to baseline framework latency with a trivial optimization task.", 4 | "Class": "Optimizer", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:OptimizePassThrough:$LATEST" 11 | } -------------------------------------------------------------------------------- /tests/core/Profiles/config/PassThroughProfile.json: -------------------------------------------------------------------------------- 1 | { 2 | "Optimizer": { 3 | "Configuration": {}, 4 | "Name": "TestSuite-ProfileTest-OptimizePassThrough" 5 | }, 6 | "ProcessingFrameRate": 10, 7 | "ChunkSize": 10, 8 | "MaxSegmentLengthSeconds": 10, 9 | "Classifier": { 10 | "Configuration": { 11 | "chunk_to_segment_ratio": "0.5" 12 | }, 13 | "Name": "TestSuite-ProfileTest-SegmentPassThrough100" 14 | }, 15 | "Labeler": { 16 | "Configuration": {}, 17 | "Name": "TestSuite-ProfileTest-LabelPassThrough" 18 | }, 19 | "Featurers": [ 20 | { 21 | "Configuration": {}, 22 | "IsPriorityForReplay": true, 23 | "Name": "TestSuite-ProfileTest-DetectPassThrough100" 24 | } 25 | ], 26 | "ContentGroups": [ 27 | "All" 28 | ], 29 | "Name": "TestSuite-ProfileTest-PassThroughPlugins" 30 | } -------------------------------------------------------------------------------- /tests/core/Profiles/config/SegmentPassThrough100.json: -------------------------------------------------------------------------------- 1 | { 2 | "Name": "TestSuite-ProfileTest-SegmentPassThrough100", 3 | "Description": "This plugin is used to test MRE in a simple way by creating segments for each chunk based on time.", 4 | "Class": "Classifier", 5 | "ExecutionType": "Sync", 6 | "SupportedMediaType": "Video", 7 | "ContentGroups": [ 8 | "All" 9 | ], 10 | "ExecuteLambdaQualifiedARN": "arn:aws:lambda:AWS_REGION:AWS_ACCOUNT_ID:function:SegmentPassThrough100:$LATEST", 11 | "Configuration": { 12 | "chunk_to_segment_ratio": "0.5" 13 | } 14 | } -------------------------------------------------------------------------------- /tests/requirements.txt: -------------------------------------------------------------------------------- 1 | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # This file was generated using pip3 freeze 5 | attrs==23.1.0 6 | aws-cdk-lib==2.90.0 7 | aws-cdk.asset-awscli-v1==2.2.200 8 | aws-cdk.asset-kubectl-v20==2.1.2 9 | aws-cdk.asset-node-proxy-agent-v5==2.0.166 10 | blessed==1.20.0 11 | boto3==1.28.44 12 | botocore==1.31.44 13 | cattrs==23.1.2 14 | certifi==2024.7.4 15 | chalice==1.29.0 16 | charset-normalizer==3.2.0 17 | click==8.1.7 18 | constructs==10.2.70 19 | execnet==2.0.2 20 | filelock==3.12.0 21 | idna==3.7 22 | importlib-resources==6.0.1 23 | iniconfig==2.0.0 24 | inquirer==2.10.1 25 | jmespath==1.0.1 26 | jsii==1.88.0 27 | packaging==23.1 28 | pluggy==1.3.0 29 | publication==0.0.3 30 | py==1.11.0 31 | pytest==7.3.1 32 | pytest-html==3.2.0 33 | pytest-metadata==3.0.0 34 | pytest-mock==3.10.0 35 | pytest-xdist==3.2.1 36 | python-dateutil==2.8.1 37 | python-editor==1.0.4 38 | PyYAML==6.0.1 39 | readchar==4.0.5 40 | requests==2.32.2 41 | requests-aws4auth==1.1.1 42 | s3transfer==0.6.2 43 | six==1.16.0 44 | typeguard==2.13.3 45 | typing_extensions==4.7.1 46 | urllib3==1.26.19 47 | wcwidth==0.2.6 48 | cdk-nag==2.28.159 -------------------------------------------------------------------------------- /tests/utils/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awslabs/aws-media-replay-engine/b10ca8cbdfe7b98ef52e5bcd2d7c1a5f88ffb15b/tests/utils/__init__.py -------------------------------------------------------------------------------- /tests/utils/config_mgr.py: -------------------------------------------------------------------------------- 1 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 2 | # SPDX-License-Identifier: MIT-0 3 | 4 | import json 5 | 6 | # Load a json file from current path 7 | def load_config(file_name): 8 | with open(file_name, 'r') as f: 9 | return json.load(f) --------------------------------------------------------------------------------