Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error generating STL #12

Open
michaelmisiaszek opened this issue Jun 22, 2024 · 0 comments
Open

Error generating STL #12

michaelmisiaszek opened this issue Jun 22, 2024 · 0 comments

Comments

@michaelmisiaszek
Copy link

Hi, I have been using the online version and could not get the app to read from a Google drive (kml file), so I saw this docker container and decided to try it out. I'm not new to docker and run containers daily. However, I am very new to python and such, but the workbooks seem really cool. Nonetheless, I'm getting an error when I run this app in my container through the starters binder. I have no idea what any of it means, so I thought I'd shoot you the log and take a peek:

Log for creating 3D model tile(s) for  10m_-118.94_48.16 
 
DEM_name = USGS/3DEP/10m 
trlat = 48.493385425999996 
trlon = -118.08383648099999 
bllat = 47.817673574000004 
bllon = -119.787156819 
printres = 0.4 
ntilesx = 1 
ntilesy = 1 
tilewidth = 120 
basethick = 0 
zscale = 1.5 
fileformat = STLb 
no_bottom = False 
lower_leq = [0, 3] 
unprojected = False 
no_normals = True 

process started: 08:39:12.996824 

Region (lat/lon):
   48.493385425999996 -118.08383648099999 (top right)
   47.817673574000004 -119.787156819 (bottom left) 
center at [-118.93549665, 48.1555295]  UTM 11 N ,  EPSG:32611 
lon/lat size in degrees: [1.7033203380000117, 0.6757118519999921] 
requesting 422.4276894135149 m resolution from EarthEngine

---------------------------------------------------------------------------
EEException                               Traceback (most recent call last)
Cell In[16], line 2
      1 # create zipfile under tmp with the STL file of the terrain model
----> 2 totalsize, full_zip_file_name = TouchTerrain.get_zipped_tiles(**args) 
      3 print("Created zip file", full_zip_file_name,  "%.2f" % totalsize, "Mb")

File /TouchTerrain/standalone/touchterrain/common/TouchTerrainEarthEngine.py:854, in get_zipped_tiles(DEM_name, trlat, trlon, bllat, bllon, polygon, polyURL, poly_file, importedDEM, printres, ntilesx, ntilesy, tilewidth, basethick, zscale, fileformat, tile_centered, CPU_cores_to_use, max_cells_for_memory_only, temp_folder, zip_file_name, no_bottom, bottom_image, ignore_leq, lower_leq, unprojected, only, original_query_string, no_normals, projection, use_geo_coords, importedGPX, gpxPathHeight, gpxPixelsBetweenPoints, gpxPathThickness, map_img_filename, smooth_borders, offset_masks_lower, fill_holes, min_elev, tilewidth_scale, clean_diags, sqrt, **otherargs)
    852     image1 = elev.mosaic().setDefaultProjection(proj) # must mosaic collection into single image
    853 else:
--> 854     image1 = ee.Image(DEM_name)
    855     info = image1.getInfo() 
    858 pr("Earth Engine raster:", info["id"])

File /usr/local/lib/python3.10/site-packages/ee/computedobject.py:32, in ComputedObjectMetaclass.__call__(cls, *args, **kwargs)
     30   return args[0]
     31 else:
---> 32   return type.__call__(cls, *args, **kwargs)

File /usr/local/lib/python3.10/site-packages/ee/image.py:56, in Image.__init__(self, args, version)
     38 def __init__(self, args=None, version=None):
     39   """Constructs an Earth Engine image.
     40 
     41   Args:
   (...)
     54     EEException: if passed something other than the above.
     55   """
---> 56   self.initialize()
     58   if version is not None:
     59     if ee_types.isString(args) and ee_types.isNumber(version):
     60       # An ID and version.

File /usr/local/lib/python3.10/site-packages/ee/image.py:102, in Image.initialize(cls)
    100 """Imports API functions to this class."""
    101 if not cls._initialized:
--> 102   apifunction.ApiFunction.importApi(cls, 'Image', 'Image')
    103   cls._initialized = True

File /usr/local/lib/python3.10/site-packages/ee/apifunction.py:183, in ApiFunction.importApi(cls, target, prefix, type_name, opt_prepend)
    170 @classmethod
    171 def importApi(cls, target, prefix, type_name, opt_prepend=None):
    172   """Adds all API functions that begin with a given prefix to a target class.
    173 
    174   Args:
   (...)
    181         added functions.
    182   """
--> 183   cls.initialize()
    184   prepend = opt_prepend or ''
    185   for name, api_func in cls._api.items():

File /usr/local/lib/python3.10/site-packages/ee/apifunction.py:154, in ApiFunction.initialize(cls)
    152 """Initializes the list of signatures from the Earth Engine front-end."""
    153 if not cls._api:
--> 154   signatures = data.getAlgorithms()
    155   api = {}
    156   for name, sig in signatures.items():
    157     # Strip type parameters.

File /usr/local/lib/python3.10/site-packages/ee/data.py:1109, in getAlgorithms()
   1093 """Get the list of algorithms.
   1094 
   1095 Returns:
   (...)
   1106               is not specified.
   1107 """
   1108 try:
-> 1109   call = _get_cloud_api_resource().projects().algorithms().list(
   1110       parent=_get_projects_path(), prettyPrint=False)
   1111 except TypeError:
   1112   call = _get_cloud_api_resource().projects().algorithms().list(
   1113       project=_get_projects_path(), prettyPrint=False)

File /usr/local/lib/python3.10/site-packages/ee/data.py:282, in _get_cloud_api_resource()
    280 def _get_cloud_api_resource():
    281   if _cloud_api_resource is None:
--> 282     raise ee_exception.EEException(
    283         'Earth Engine client library not initialized. Run `ee.Initialize()`')
    284   return _cloud_api_resource

EEException: Earth Engine client library not initialized. Run `ee.Initialize()`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant