Skip to content

Commit

Permalink
chore: Changed naming and added descriptions.
Browse files Browse the repository at this point in the history
Changed from underscores to dashes. Added per field and per table descriptions.
  • Loading branch information
goog-pegman committed Jun 8, 2021
1 parent 9c4462d commit 42001b0
Showing 1 changed file with 86 additions and 21 deletions.
107 changes: 86 additions & 21 deletions datasets/vaccination_access/vaccination_access_to_bq/pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,21 @@
---
resources:
- type: bigquery_table
table_id: facility_boundary_us_all
table_id: facility-boundary-us-all
description: "This table is formed by combining the data from the individual US tables of drive, transit and walk. It represents the boundaries of areas surrounding vaccination facilities from which people can reach the facility within certain duration. It is computed for 3 travel modes of drive, transit and walk and for predetermined time periods."
- type: bigquery_table
table_id: facility_boundary_us_drive
table_id: facility-boundary-us-drive
description: "This table represents the boundaries of areas surrounding vaccination facilities from which people can reach the facility by driving within predetermined time periods."
- type: bigquery_table
table_id: facility_boundary_us_transit
table_id: facility-boundary-us-transit
description: "This table represents the boundaries of areas surrounding vaccination facilities from which people can reach the facility by public transit within predetermined time periods."
- type: bigquery_table
table_id: facility_boundary_us_walk
table_id: facility-boundary-us-walk
description: "This table represents the boundaries of areas surrounding vaccination facilities from which people can reach the facility by walking within predetermined time periods."

dag:
initialize:
dag_id: vaccination_access_to_bq
dag_id: covid19-vaccination-access_to_bq
default_args:
owner: "Google"
depends_on_past: False
Expand All @@ -37,232 +41,293 @@ dag:

tasks:
- operator: "GoogleCloudStorageToBigQueryOperator"
description: "Task to load CSV file from covid19-open-data bucket to facility_boundary_us_all"
description: "Task to load CSV file from covid19-open-data bucket to facility-boundary-us-all"
args:
task_id: "gcs_to_bq_table_us_all"
bucket: "{{ var.json.vaccination_access.source_bucket }}"
source_objects: ["{{ var.json.vaccination_access.source_prefix }}/facility_boundary_us_all.csv"]
bucket: "{{ var.json.covid19-vaccination-access.source_bucket }}"
source_objects: ["{{ var.json.covid19-vaccination-access.source_prefix }}/facility-boundary-us-all.csv"]
source_format: "CSV"
destination_project_dataset_table: "vaccination_access.facility_boundary_us_all"
destination_project_dataset_table: "covid19-vaccination-access.facility-boundary-us-all"
skip_leading_rows: 1
write_disposition: "WRITE_TRUNCATE"
schema_fields:
- name: "facility_place_id"
type: "STRING"
mode: "REQUIRED"
description: "The Google Place ID of the vaccination site. For example, ChIJV3woGFkSK4cRWP9s3-kIFGk."
- name: "facility_provider_id"
type: "STRING"
mode: "NULLABLE"
description: "An identifier imported from the provider of the vaccination site information. In the US, we use the ID provided by VaccineFinder when available. For example, 7ede5bd5-44da-4a59-b4d9-b3a49c53472c."
- name: "facility_name"
type: "STRING"
mode: "NULLABLE"
description: "The name of the vaccination site. For example, St. Joseph's Hospital."
- name: "facility_latitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The latitude of the vaccination site. For example, 36.0507"
- name: "facility_longitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The longitude of the vaccination site. For example, 41.4356"
- name: "facility_country_region"
type: "STRING"
mode: "NULLABLE"
description: "The name of the country or region in English. For example, United States."
- name: "facility_country_code"
type: "STRING"
mode: "NULLABLE"
description: "The ISO 3166-1 code for the country or region. For example, US."
- name: "facility_sub_region_1"
type: "STRING"
mode: "NULLABLE"
description: "The name of a region in the country. For example, California."
- name: "facility_sub_region_1_code"
type: "STRING"
mode: "NULLABLE"
description: "A country-specific ISO 3166-2 code for the region. For example, US-CA."
- name: "facility_sub_region_2"
type: "STRING"
mode: "NULLABLE"
description: "The name (or type) of a region in the country. Typically a subdivision of sub_region_1. For example, Santa Clara County or municipal_borough."
- name: "facility_sub_region_2_code"
type: "STRING"
mode: "NULLABLE"
description: "In the US, the FIPS code for a US county (or equivalent). For example, 06085."
- name: "facility_region_place_id"
type: "STRING"
mode: "NULLABLE"
description: "The Google place ID for the most-specific region, used in Google Places API and on Google Maps. For example, ChIJd_Y0eVIvkIARuQyDN0F1LBA."
- name: "mode_of_transportation"
type: "STRING"
mode: "NULLABLE"
description: "The mode of transport used to calculate the catchment boundary. For example, driving."
- name: "travel_time_threshold_minutes"
type: "INTEGER"
mode: "NULLABLE"
description: "The maximum travel time, in minutes, used to calculate the catchment boundary. For example, 30."
- name: "facility_catchment_boundary"
type: "GEOGRAPHY"
mode: "NULLABLE"
description: "A GeoJSON representation of the catchment area boundary of the site, for a particular mode of transportation and travel time threshold. Consists of multiple latitude and longitude points."

- operator: "GoogleCloudStorageToBigQueryOperator"
description: "Task to load CSV file from covid19-open-data bucket to facility_boundary_us_drive"
description: "Task to load CSV file from covid19-open-data bucket to facility-boundary-us-drive"
args:
task_id: "gcs_to_bq_table_us_drive"
bucket: "{{ var.json.vaccination_access.source_bucket }}"
source_objects: ["{{ var.json.vaccination_access.source_prefix }}/facility_boundary_us_drive.csv"]
bucket: "{{ var.json.covid19-vaccination-access.source_bucket }}"
source_objects: ["{{ var.json.covid19-vaccination-access.source_prefix }}/facility-boundary-us-drive.csv"]
source_format: "CSV"
destination_project_dataset_table: "vaccination_access.facility_boundary_us_drive"
destination_project_dataset_table: "covid19-vaccination-access.facility-boundary-us-drive"
skip_leading_rows: 1
write_disposition: "WRITE_TRUNCATE"
schema_fields:
- name: "facility_place_id"
type: "STRING"
mode: "REQUIRED"
description: "The Google Place ID of the vaccination site. For example, ChIJV3woGFkSK4cRWP9s3-kIFGk."
- name: "facility_provider_id"
type: "STRING"
mode: "NULLABLE"
description: "An identifier imported from the provider of the vaccination site information. In the US, we use the ID provided by VaccineFinder when available. For example, 7ede5bd5-44da-4a59-b4d9-b3a49c53472c."
- name: "facility_name"
type: "STRING"
mode: "NULLABLE"
description: "The name of the vaccination site. For example, St. Joseph's Hospital."
- name: "facility_latitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The latitude of the vaccination site. For example, 36.0507"
- name: "facility_longitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The longitude of the vaccination site. For example, 41.4356"
- name: "facility_country_region"
type: "STRING"
mode: "NULLABLE"
description: "The name of the country or region in English. For example, United States."
- name: "facility_country_code"
type: "STRING"
mode: "NULLABLE"
description: "The ISO 3166-1 code for the country or region. For example, US."
- name: "facility_sub_region_1"
type: "STRING"
mode: "NULLABLE"
description: "The name of a region in the country. For example, California."
- name: "facility_sub_region_1_code"
type: "STRING"
mode: "NULLABLE"
description: "A country-specific ISO 3166-2 code for the region. For example, US-CA."
- name: "facility_sub_region_2"
type: "STRING"
mode: "NULLABLE"
description: "The name (or type) of a region in the country. Typically a subdivision of sub_region_1. For example, Santa Clara County or municipal_borough."
- name: "facility_sub_region_2_code"
type: "STRING"
mode: "NULLABLE"
description: "In the US, the FIPS code for a US county (or equivalent). For example, 06085."
- name: "facility_region_place_id"
type: "STRING"
mode: "NULLABLE"
description: "The Google place ID for the most-specific region, used in Google Places API and on Google Maps. For example, ChIJd_Y0eVIvkIARuQyDN0F1LBA."
- name: "mode_of_transportation"
type: "STRING"
mode: "NULLABLE"
description: "The mode of transport used to calculate the catchment boundary. For example, driving."
- name: "travel_time_threshold_minutes"
type: "INTEGER"
mode: "NULLABLE"
description: "The maximum travel time, in minutes, used to calculate the catchment boundary. For example, 30."
- name: "facility_catchment_boundary"
type: "GEOGRAPHY"
mode: "NULLABLE"
description: "A GeoJSON representation of the catchment area boundary of the site, for a particular mode of transportation and travel time threshold. Consists of multiple latitude and longitude points."

- operator: "GoogleCloudStorageToBigQueryOperator"
description: "Task to load CSV file from covid19-open-data bucket to facility_boundary_us_transit"
description: "Task to load CSV file from covid19-open-data bucket to facility-boundary-us-transit"
args:
task_id: "gcs_to_bq_table_us_transit"
bucket: "{{ var.json.vaccination_access.source_bucket }}"
source_objects: ["{{ var.json.vaccination_access.source_prefix }}/facility_boundary_us_transit.csv"]
bucket: "{{ var.json.covid19-vaccination-access.source_bucket }}"
source_objects: ["{{ var.json.covid19-vaccination-access.source_prefix }}/facility-boundary-us-transit.csv"]
source_format: "CSV"
destination_project_dataset_table: "vaccination_access.facility_boundary_us_transit"
destination_project_dataset_table: "covid19-vaccination-access.facility-boundary-us-transit"
skip_leading_rows: 1
write_disposition: "WRITE_TRUNCATE"
schema_fields:
- name: "facility_place_id"
type: "STRING"
mode: "REQUIRED"
description: "The Google Place ID of the vaccination site. For example, ChIJV3woGFkSK4cRWP9s3-kIFGk."
- name: "facility_provider_id"
type: "STRING"
mode: "NULLABLE"
description: "An identifier imported from the provider of the vaccination site information. In the US, we use the ID provided by VaccineFinder when available. For example, 7ede5bd5-44da-4a59-b4d9-b3a49c53472c."
- name: "facility_name"
type: "STRING"
mode: "NULLABLE"
description: "The name of the vaccination site. For example, St. Joseph's Hospital."
- name: "facility_latitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The latitude of the vaccination site. For example, 36.0507"
- name: "facility_longitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The longitude of the vaccination site. For example, 41.4356"
- name: "facility_country_region"
type: "STRING"
mode: "NULLABLE"
description: "The name of the country or region in English. For example, United States."
- name: "facility_country_code"
type: "STRING"
mode: "NULLABLE"
description: "The ISO 3166-1 code for the country or region. For example, US."
- name: "facility_sub_region_1"
type: "STRING"
mode: "NULLABLE"
description: "The name of a region in the country. For example, California."
- name: "facility_sub_region_1_code"
type: "STRING"
mode: "NULLABLE"
description: "A country-specific ISO 3166-2 code for the region. For example, US-CA."
- name: "facility_sub_region_2"
type: "STRING"
mode: "NULLABLE"
description: "The name (or type) of a region in the country. Typically a subdivision of sub_region_1. For example, Santa Clara County or municipal_borough."
- name: "facility_sub_region_2_code"
type: "STRING"
mode: "NULLABLE"
description: "In the US, the FIPS code for a US county (or equivalent). For example, 06085."
- name: "facility_region_place_id"
type: "STRING"
mode: "NULLABLE"
description: "The Google place ID for the most-specific region, used in Google Places API and on Google Maps. For example, ChIJd_Y0eVIvkIARuQyDN0F1LBA."
- name: "mode_of_transportation"
type: "STRING"
mode: "NULLABLE"
description: "The mode of transport used to calculate the catchment boundary. For example, driving."
- name: "travel_time_threshold_minutes"
type: "INTEGER"
mode: "NULLABLE"
description: "The maximum travel time, in minutes, used to calculate the catchment boundary. For example, 30."
- name: "facility_catchment_boundary"
type: "GEOGRAPHY"
mode: "NULLABLE"
description: "A GeoJSON representation of the catchment area boundary of the site, for a particular mode of transportation and travel time threshold. Consists of multiple latitude and longitude points."


- operator: "GoogleCloudStorageToBigQueryOperator"
description: "Task to load CSV file from covid19-open-data bucket to facility_boundary_us_walk"
description: "Task to load CSV file from covid19-open-data bucket to facility-boundary-us-walk"
args:
task_id: "gcs_to_bq_table_us_walk"
bucket: "{{ var.json.vaccination_access.source_bucket }}"
source_objects: ["{{ var.json.vaccination_access.source_prefix }}/facility_boundary_us_walk.csv"]
bucket: "{{ var.json.covid19-vaccination-access.source_bucket }}"
source_objects: ["{{ var.json.covid19-vaccination-access.source_prefix }}/facility-boundary-us-walk.csv"]
source_format: "CSV"
destination_project_dataset_table: "vaccination_access.facility_boundary_us_walk"
destination_project_dataset_table: "covid19-vaccination-access.facility-boundary-us-walk"
skip_leading_rows: 1
write_disposition: "WRITE_TRUNCATE"
schema_fields:
- name: "facility_place_id"
type: "STRING"
mode: "REQUIRED"
description: "The Google Place ID of the vaccination site. For example, ChIJV3woGFkSK4cRWP9s3-kIFGk."
- name: "facility_provider_id"
type: "STRING"
mode: "NULLABLE"
description: "An identifier imported from the provider of the vaccination site information. In the US, we use the ID provided by VaccineFinder when available. For example, 7ede5bd5-44da-4a59-b4d9-b3a49c53472c."
- name: "facility_name"
type: "STRING"
mode: "NULLABLE"
description: "The name of the vaccination site. For example, St. Joseph's Hospital."
- name: "facility_latitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The latitude of the vaccination site. For example, 36.0507"
- name: "facility_longitude"
type: "FLOAT"
mode: "REQUIRED"
description: "The longitude of the vaccination site. For example, 41.4356"
- name: "facility_country_region"
type: "STRING"
mode: "NULLABLE"
description: "The name of the country or region in English. For example, United States."
- name: "facility_country_code"
type: "STRING"
mode: "NULLABLE"
description: "The ISO 3166-1 code for the country or region. For example, US."
- name: "facility_sub_region_1"
type: "STRING"
mode: "NULLABLE"
description: "The name of a region in the country. For example, California."
- name: "facility_sub_region_1_code"
type: "STRING"
mode: "NULLABLE"
description: "A country-specific ISO 3166-2 code for the region. For example, US-CA."
- name: "facility_sub_region_2"
type: "STRING"
mode: "NULLABLE"
description: "The name (or type) of a region in the country. Typically a subdivision of sub_region_1. For example, Santa Clara County or municipal_borough."
- name: "facility_sub_region_2_code"
type: "STRING"
mode: "NULLABLE"
description: "In the US, the FIPS code for a US county (or equivalent). For example, 06085."
- name: "facility_region_place_id"
type: "STRING"
mode: "NULLABLE"
description: "The Google place ID for the most-specific region, used in Google Places API and on Google Maps. For example, ChIJd_Y0eVIvkIARuQyDN0F1LBA."
- name: "mode_of_transportation"
type: "STRING"
mode: "NULLABLE"
description: "The mode of transport used to calculate the catchment boundary. For example, driving."
- name: "travel_time_threshold_minutes"
type: "INTEGER"
mode: "NULLABLE"
description: "The maximum travel time, in minutes, used to calculate the catchment boundary. For example, 30."
- name: "facility_catchment_boundary"
type: "GEOGRAPHY"
mode: "NULLABLE"
description: "A GeoJSON representation of the catchment area boundary of the site, for a particular mode of transportation and travel time threshold. Consists of multiple latitude and longitude points."

graph_paths:
- "gcs_to_bq_table_us_all"
Expand Down

0 comments on commit 42001b0

Please sign in to comment.