Skip to content

Latest commit

 

History

History
125 lines (86 loc) · 7.28 KB

README.md

File metadata and controls

125 lines (86 loc) · 7.28 KB

Hawaii Zoning Atlas

🏖️ 🌋 🌐

Interactive map showing how outdated zoning laws make it hard to build diverse, affordable housing in Hawaii

Developed by Code with Aloha

Philosophy

This interactive map shows how outdated zoning laws make it hard to build diverse, affordable housing.

Zoning laws, adopted by thousands of local governments across the country, dictate much of what can be built in the United States. We need to find better ways of helping people understand what zoning codes say, because they have a tremendous impact on our economy, on the environment, and on our society. A zoning atlas that enables users to visualize the prevalence and nature of regulatory constraints, particularly on housing, can be an important tool to achieve that goal.

Partners, Supporters, and Sponsors

Resources

News Articles

New Developers Start Here

The code can be seen live at hawaiizoningatlas.com

The process of moving the data from the starting point (the datasheet) to the final destination (the website) involves a series of processes that we are hoping to automate.

Data Pipeline

The goal of the data pipeline is to help decrease the friction between getting data from the spreadsheet to the final form hosted by the website.

In the HZA Research Guide The user can find the starting point for the map which is the datasheet.

This datasheet is manually populated by people going through the various zoning laws (The links for the zoning laws are found in the repo's research guide.) and filling out cells according to the guidelines laid out in How to Make a Zoning Atlas.

After the data sheet is populated, it is then exported to a csv where the following steps need to occur:

  • The county tabs are combined together
  • Validation is run on the data
  • The final csv is given the name hawaii-zoning-data.csv

The hawaii-zoning-data.csv file should then be placed into the data-pipeline folder.

In the data-pipeline folder there is a "gis" folder that holds the output of processing various shape files. These shape files come from the maps given in the HZA Research Guide. The method of processing the shape files is outlined in How to Make a Zoning Atlas.

Data Processing

Once the data has been aggregated and in the correct form, it is processed by the CombineJurisdictions Jupyter Notebook. The notebook exports the final.geojson file that is placed in the repository's "data" directory. This is the data the populates the website.

Automation Goals

GitHub actions is the tool we are using to automate the various parts of the data processing pipeline.

Different GitHub actions will perform the following tasks:

  • Pull the data from the datasheet into a csv that combines the counties
  • Run validation to ensure that the data is correct (prevent mistypings, blank lines, etc)
  • Commit the validated and changed files to the repository
sequenceDiagram
    participant Actions
    participant Spreadsheet

    Actions->>Spreadsheet: Pull data for all the counties (Maui, Oahu, Big Island, Kauai)

    loop Validation
        Actions->>Actions: Validate the pulled data against a schema (prevent mistypings, blank lines, ...etc)
    end

    loop Commit
        Actions->>Actions: Commit the validated and changed files to this repository
    end
Loading

Once the data is ready for processing, another set of actions will perform the following tasks:

  • Run the data through the CombineJurisdiction notebook
  • Minimize the final.geojson file
  • Commit the final.geojson file to the repository
    • The name of the final.geojson should include a timestamp and a reference to the original data used to generate it. This will allow us to rollback to different versions if needed.
sequenceDiagram
    participant Actions
    participant Jupyter Notebook

    Actions->>Jupyter Notebook: Execute the Jupyter Notebook with all the prerequisite files (`gis/`, `csv/`, ...etc) 

    Jupyter Notebook->>Actions: Return a `final.geojson` to be served with the map

    loop Commit
        Actions->>Actions: Commit the generated `final.geojson` to the repository
    end
Loading