Skip to main content

index

Objects

BaseInput

@dataclass
class BaseInput()

Input for running the main lambda handler.

Attributes:

  • job_id str - Job ID.
  • output_key str, optional - object path to write the annotations to, best to use the same path as the tiles.
  • target_bucket str, optional - output bucket to write annotations to.

Functions

lambda_handler

@tracer.capture_lambda_handler
@logger.inject_lambda_context()
def lambda_handler(event: dict, context: dict) -> dict

Function to write a CSV containing all annotations for a specific Job. Will parse DynamoDB and S3 payloads into annotation csv.

Arguments:

  • event dict - should fit the BaseInput.
  • context dict - lambda context object.

Returns:

  • dict - source event with csv as an added key. This is the object path of the annotation.csv file.
{
"job_id": "qiupu302930-1337-q9m23ueq923umeq938uxe9q23",
"output_key": "/some/output/path/",
"target_bucket": "some-bucket"
}