You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+66-3Lines changed: 66 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,13 +34,76 @@ Makefile # Dev workflow commands
34
34
pip install -r requirements.txt
35
35
```
36
36
37
-
### 2. Run Tests
37
+
### 2. (Optional) Stand Up PostGIS via Docker
38
+
39
+
If you want to use the PostGIS-backed analyzer, bring up a local PostGIS container:
40
+
41
+
```sh
42
+
docker run \
43
+
--name suntrace-postgis \
44
+
-e POSTGRES_DB=suntrace \
45
+
-e POSTGRES_USER=pguser \
46
+
-e POSTGRES_PASSWORD=pgpass \
47
+
-p 5432:5432 \
48
+
-d postgis/postgis:15-3.4
49
+
```
50
+
51
+
Wait for the database to accept connections, then ensure the PostGIS extensions exist (the analyzer can do this for you, or run once inside the container):
52
+
53
+
```sh
54
+
docker exec -it suntrace-postgis psql -U pguser -d suntrace -c "CREATE EXTENSION IF NOT EXISTS postgis;"
55
+
docker exec -it suntrace-postgis psql -U pguser -d suntrace -c "CREATE EXTENSION IF NOT EXISTS postgis_topology;"
56
+
```
57
+
58
+
### 3. Load Project Data into PostGIS
59
+
60
+
With the container running and data available under `data/`, load all vector layers:
> The script scans `data/`, `data/lamwo_sentinel_composites/`, `data/viz_geojsons/`, and `data/sample_region_mudu/`, writing tables such as `public.lamwo_buildings`, `public.lamwo_roads`, `public.lamwo_tile_stats_ee_biomass`, etc. Ensure filenames follow the repository defaults so table names match the analyzer’s expectations.
77
+
78
+
If you need the joined tile view, run inside a Python shell after the load:
79
+
80
+
```python
81
+
from utils.GeospatialAnalyzer2 import GeospatialAnalyzer2
0 commit comments