def _s3_resource(dallinger_region=False):
config = get_config()<EOL>if not config.ready:<EOL><INDENT>config.load()<EOL><DEDENT>region = "<STR_LIT>" if dallinger_region else config.get("<STR_LIT>")<EOL>return boto3.resource(<EOL>"<STR_LIT>",<EOL>region_name=region,<EOL>aws_access_key_id=config.get("<STR_LIT>"),<EOL>aws_secret_access_key=config.get("<STR_LIT>"),<EOL>)<EOL>
A boto3 S3 resource using the AWS keys in the config.