View a markdown version of this page

Developer guide - Scene Intelligence with Rosbag on AWS

Developer guide

This section provides the source code for the solution and additional customizations.

Source code

Visit our GitHub repository to download the source files for this solution and to share your customizations with others.

Customization guide

The DAG and Apache Spark code are located in the artifacts S3 bucket. The artifacts bucket has the naming pattern of addf-aws-solutions-artifacts-bucket- <hash>. The following is an example:

s3://addf-aws-solutions-artifacts-bucket-<hash>/dags/aws-solutions/analysis-rip/image_dags/*

In this location, the detect_scenes.py file houses the Apache Spark code that applies the business logic. You can access this file, modify it to suit your use case, upload it to same S3 bucket, and re-run the DAG in its entirety (rosbag extraction and object detection along with the Spark business logic).

Note

If you’re only testing the Apache Spark changes, you can just re-run the Amazon EMR Serverless job in the application. A simple clone of a previously-run job runs your Apache Spark changes. Set the Apache Spark properties to include the DynamoDB-Spark.jar file. For instructions, see Running jobs from the EMR Studio console.