Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion component/scripts/logging_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

# rio-tiler emits ``NoOverviewWarning`` once per tile when a source raster has no
# overviews. The raster-add paths now build overviews up front
# (``SbaeMap.add_class_raster`` -> ``prepare_for_tiles``), so this warning is
# (``SepalMap.add_raster`` -> ``prepare_for_tiles``), so this warning is
# non-actionable noise here; silence it so any raster that still slips through a
# fallback path cannot flood the logs with hundreds of identical lines.
try:
Expand Down
231 changes: 0 additions & 231 deletions component/scripts/tiling.py

This file was deleted.

6 changes: 3 additions & 3 deletions component/tile/upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from typing import Any, Dict

import solara
from pysepal.mapping import prepare_for_tiles
from sepal_ui.sepalwidgets.file_input import FileInputComponent
from sepal_ui.solara.notifications import use_notifications

Expand All @@ -14,7 +15,6 @@
get_file_info,
is_raster_file,
)
from component.scripts.tiling import prepare_for_tiles
from component.widget.map import SbaeMap

logger = logging.getLogger("sbae.upload")
Expand All @@ -34,11 +34,11 @@ def add_optimized_raster_to_map():
and status == "adding_to_map"
and sampling_method == "stratified"
):
sbae_map.add_class_raster(
sbae_map.add_raster(
optimized_path,
app_state.class_colors.value,
layer_name="Classification Map",
key="clas",
class_colors=app_state.class_colors.value,
)
app_state.raster_optimization_status.value = "finished"

Expand Down
10 changes: 5 additions & 5 deletions component/widget/analysis_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ def derive_map_source(state, sbae_map=None):
state.analysis_reference_df.value = ref_out

# Standalone mode never runs the design-step upload that populates
# class_colors, so it's empty here -- without this, add_class_raster falls
# class_colors, so it's empty here -- without this, add_raster falls
# back to a continuous colormap and the map renders near-black. Derive it
# from the raster; guarded so a real design-step palette is kept.
if not state.class_colors.value:
Expand All @@ -176,11 +176,11 @@ def derive_map_source(state, sbae_map=None):

if sbae_map is not None:
try:
sbae_map.add_class_raster(
sbae_map.add_raster(
raster,
state.class_colors.value or {},
"Classification (analysis)",
"clas_an",
layer_name="Classification (analysis)",
key="clas_an",
class_colors=state.class_colors.value or {},
)
# Reference points are drawn by the panel's render thread (from
# analysis_reference_df, for every source) on their own layer.
Expand Down
Loading
Loading