Download Latest Version v1.4.2 source code.zip (754.4 kB) Google Add to Preferred Sources
Home / v1.3.3
Name Modified Size InfoDownloads / Week
Parent folder
README.md 2026-06-14 1.3 kB
v1.3.3 source code.tar.gz 2026-06-14 593.8 kB
v1.3.3 source code.zip 2026-06-14 685.6 kB
Totals: 3 Items   1.3 MB 0

What's changed

REST API (samgeo.api) robustness fixes, validated end-to-end against the example imagery in docs/examples/ (#535):

  • Model cache mode collision — the cache key now folds in the model-shaping kwargs (automatic, backend, confidence_threshold, points_per_side, pred_iou_thresh, stability_score_thresh), so an automatic mask-generation instance is no longer reused for a prompt-predict request ('SamGeo2' object has no attribute 'predictor'), and requests that differ only by configuration no longer silently reuse a stale instance.
  • SAM3 second-request dtype error — SAM3 mutates its encoded-image state during generate_*, so the image-hash optimization made the 2nd+ SAM3 request fail with expected scalar type BFloat16 but found Float. _set_image_cached now always re-encodes for SAM3 (SAM/SAM2 still cached).
  • Empty-mask vectorization — raster_to_vector now emits a valid empty FeatureCollection instead of raising geopandas' "no active geometry column" when a mask has no foreground.
  • /segment/automatic gained the empty-masks 404 guard the other endpoints have, and now defaults to SAM3.

Added regression tests for all of the above.

Full diff: https://github.com/opengeos/segment-geospatial/compare/v1.3.2...v1.3.3

Source: README.md, updated 2026-06-14