giswqs commited on
Commit
7e6afcd
·
verified ·
1 Parent(s): 2a040e5

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +2 -1
main.py CHANGED
@@ -2,6 +2,7 @@ import os
2
  import json
3
  import ee
4
  import geemap
 
5
  import gradio as gr
6
  from fastapi import FastAPI, HTTPException
7
  from pydantic import BaseModel
@@ -13,7 +14,7 @@ if "EARTHENGINE_TOKEN" not in os.environ:
13
  raise RuntimeError("EARTHENGINE_TOKEN environment variable not found")
14
 
15
  try:
16
- geemap.ee_initialize()
17
  except Exception as e:
18
  raise RuntimeError(f"Earth Engine authentication failed: {e}")
19
 
 
2
  import json
3
  import ee
4
  import geemap
5
+ import leafmap
6
  import gradio as gr
7
  from fastapi import FastAPI, HTTPException
8
  from pydantic import BaseModel
 
14
  raise RuntimeError("EARTHENGINE_TOKEN environment variable not found")
15
 
16
  try:
17
+ leafmap.ee_initialize()
18
  except Exception as e:
19
  raise RuntimeError(f"Earth Engine authentication failed: {e}")
20