HGS FLOOD2D - SETUP AND USE
===========================
HydroGeoSolutions | Watershed Flood Modelling Pipeline v1.1

WHAT THIS FOLDER CONTAINS
  setup.bat            one-time installer (double-click once)
  RUN_Flood2D.bat                drag-and-drop runner for flood simulations
  RUN_HECRAS_PostProcessor.bat   drag-and-drop runner for HEC-RAS plan HDF files (Path B)
  hgs_flood2d.py                 2D flood engine (Bates et al. 2010 scheme)
  hgs_ras2d_postprocessor.py     HEC-RAS results post-processor (also used by the engine)

INSTALL (once per computer)
  1. Copy this whole folder anywhere on the PC (e.g. D:\HGS_Flood2D).
  2. Double-click setup.bat and wait for "Installation complete".
     Needs internet. If Python is missing it is installed automatically.

USE (every project)
  1. Open the Watershed Flood Modelling Assistant on the portal:
     https://portal.hydrogeosolutions.synology.me  (Watershed tool page)
  2. Draw/upload the watershed, fetch rainfall, build storms and
     hydrographs (Tabs 1-4), then Tab 1 -> "Save Project (JSON)".
  3. Drag the saved JSON onto RUN_Flood2D.bat.
     Outputs (GeoTIFF maps, inundation shapefile, PNG maps, Excel
     summary) appear in a folder named <ProjectCode>_flood2d.

  Own DEM (Cartosat/survey):  RUN_Flood2D.bat project.json --dem site_dem.tif
  Selected return periods:    RUN_Flood2D.bat project.json --rp 25,100

MAC / LINUX
  pip install numpy pandas scipy matplotlib pillow requests pyproj xlsxwriter h5py rasterio geopandas shapely
  python hgs_flood2d.py project.json

NOTES
  - Everything installs into the local "venv" folder; nothing else on
    the PC is modified. Delete the folder to uninstall completely.
  - Results are screening/proposal grade; for statutory submissions run
    HEC-RAS 2D with the same boundary data and use
    RUN_HECRAS_PostProcessor.bat on the plan HDF.
