Closed 12rambau closed 3 years ago
By default tiles are saved in tempfile.TemporaryDirectory(prefix='xarray_leaflet_')
. On Linux this will translate to a path starting with /tmp/xarray_leaflet_
. So you can e.g. ls -lrt /tmp
and see if something has been written there.
In the browser you could look at the network analyzer and see the status of the requests corresponding to the tiles.
Well, I gave all I had but it's clearly beyond my skills ;-)
The tmp/xarray_leaflet_turlutut/
folder is never filled or created so I don't have any tiles to load. but the tmp
can be written so normally no problem there.
I don't see any requests in the network analyser, I have the feeling that this step is never reached.
I want to mention that our env is in Python 3.6.9 and that my ipyleaflet
version is limited to 0.13.3 by geemap
. but I don't see any problem according to your setup.py.
I tried to display a lot of intermediate output to see where it was blocked but I can't get the output_debug
to work properly. It writes the first print
statement but as soon as we go to async def
or functions called by the observe
on "bounds"
I see nothing.
The shape of the url to fetch the tiles (base_url
) must look like the following right:
https://sepal.io/api/sandbox/jupyter
Basically everything up to the first "jupyter"
That makes a final url of the form :
https://sepal.io/api/sandbox/jupyter/xarray_leaflet/tmp/xarray_leaflet_turlututu/{z}/{x}/{y}.png
If this is the case, I have to modify the base_url
construction, I made a mistake for lab in my last PR.
Then if I set fit_bounds
to False
, async_wait_for_bounds
doesn't launch if I don't zoom right ?
@12rambau You can update ipyleaflet to the latest version and geemap should work just fine. The reason I put ipyleaflet v0.13.3 is because ipyleaflet>0.13.3 pip installation does not work properly on Windows https://github.com/jupyter-widgets/ipyleaflet/issues/769. For conda installation, geemap should automatically install the latest ipyleaflet. https://github.com/conda-forge/geemap-feedstock/blob/master/recipe/meta.yaml
@giswqs is it still working on your side in geemap ?
I just tested the notebook example on my Linux machine with Python 3.8 and ipyleaflet 0.13.6. It works fine.
https://geemap.org/notebooks/25_load_rasters
https://user-images.githubusercontent.com/5016453/111326687-24026680-8643-11eb-9d45-465c1fcd7724.mp4
ok so I welcome myself in the compatibility nightmare
I think I find a solution.
ipyleaflet
and traitlet
to the latest available on 3.6.9 (i.e. -> 4.3.3)PROJ_LIB
env variable to ue your libGood thing though is that now that I really dig in your code @davidbrochart, I better understand what you've done and better understand the power of async function. Thanks and congrats !
I will close this issue once everything is set on the prod
env of the SEPAL website
It should work but instead the spinning wheel turns forever and nothing appears on the map.
Hi, I'm experiencing this issue as well on both Linux and Mac.
Linux:
I'm trying to use xarray_leaflet in a notebook running in a Ubuntu-based Docker container on a JupyterHub. I initially encountered this issue while working on my own notebook, but I am able to replicate it with the introduction.ipynb notebook. I see a /tmp/xarray_leaflet_*
directory, but it is empty. The "loading" wheel spins endlessly
Mac:
Again, I've tried both my own notebook and the introduction.ipynb demo notebook from this repo. The /var/folders/**/**/**/xarray_leaflet_*
directory exists and the tiles appear to be written. The map remains blank aside from the basemap, however.
I do not encounter this issue in the Binder for this repo.
Maybe you could have a look at the debug_output
in the dynamic.ipynb
notebook?
if self.url.endswith('/lab'):
# we are in JupyterLab
self.base_url = self.url[:-4]
to
if self.url.find('/lab/') != -1:
# we are in JupyterLab
i_lab=self.url.find('/lab/')
self.base_url = self.url[:i_lab]
See #45
I know that this is the exact same title as #39 But as the OP now have a solution that cannot be used in my case I preferred to open a new one.
I'm working on a company environment so I have no opportunity to start from a "fresh" conda env and I'm force to better understand the libs we use. We were using the lib to display raster as in the geemap librairy and it was working very effectivelly.
As referred here, we recently lost the abbility to load anything on the map...
I checked my configuration over the one in setup.py
It should work but instead the spinning wheel turns forever and nothing appears on the map.
I also check the javascript console and appart from warnings about the cartoDB basemap, nothing.
Would you think about anything that could prevent the loading of the generated tiles ? (I'm in particular thinking about authorization to read or write in specific folder but I don't knwo which one to verify)