A Python package for geospatial analysis and interactive mapping in a Jupyter environment.
Create a small module that builds interactive maps that can switch between a notebook-friendly widget backend and an HTML-friendly backend while keeping overlays and controls consistent.
@generates
from typing import Literal, Sequence, Mapping, Any
Backend = Literal["widget", "html"]
def create_map(backend: Backend, center: Sequence[float], zoom: int = 3) -> Any:
"""Create an interactive map using the selected backend with a base layer and overlay toggle."""
def add_geojson_overlay(map_obj: Any, geojson_path: str, style: Mapping[str, Any] | None = None, tooltip_field: str | None = None) -> None:
"""Load a GeoJSON file onto the map with optional styling and tooltip display."""
def enable_interactive_controls(map_obj: Any, search_placeholder: str = "Search for places") -> None:
"""Add drawing, measurement, and place search controls to the map."""
def export_map(map_obj: Any, output_html: str) -> str:
"""Save the interactive map (including overlays and user drawings) to an HTML file and return its path."""Provides multi-backend interactive maps with built-in search, draw, and measurement controls for notebook and HTML outputs.
tessl i tessl/pypi-leafmap@0.52.0docs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10