report-generator

Report Generator

This project generates a PDF report for a specified county using GeoJSON data and infographics. The report includes a map highlighting the county and a bar chart with sample data.

Features

Requirements

Installation

  1. Clone the repository:
    git clone https://github.com/yourusername/report-generator.git
    cd report-generator
    
  2. Create a virtual environment and activate it:

    python -m venv venv
    source venv/bin/activate
    
  3. Install the required packages:

    pip install -r requirements.txt
    
  4. Install wkhtmltopdf:
    • For Ubuntu:
      sudo apt-get install wkhtmltopdf
      
    • For macOS:
      brew install wkhtmltopdf
      
    • For Windows:
      • Download the installer from the wkhtmltopdf website.
      • Add the installation directory to the system PATH.
      • Restart the terminal.
      • Verify the installation by running wkhtmltopdf --version.
    • If the installation was successful, you should see the version number.

Usage

Run the script:

python python main.py build

python main.py build -t extremeheat
python main.py build -t airpollution
python main.py build (or -t all) to generate both.

Make sure geckodriver is up to date and in your PATH. You can download it from here.