Python package to integrate image pyramids and raster/vector algorithms for computer vision at Port of Barcelona. Allows text, bounding box and point-based segmentation based on SAMGeo and GroundingDINO. Please refer to the homepage https://victorpachecoaznar.github.io/TFG/
Project description
TFG
This repository hosts the code for my Bachelors' thesis in Geoinfomation and Geomatics Engineering. The project has been tutored by Port de Barcelona and Universitat Politècnica de Catalunya.
Please refer to the homepage of the project:
🏡 https://victorpachecoaznar.github.io/TFG/
About this package
The goal of APB_spatial_computer_vision is to provide a framework to perform computer vision tasks on geospatial imagery. Its focus is semantic segmentation, mainly though SAM. The logic can be accessed in several points:
- Through text, to perform image to bbox tasks via Grounding DINO.
- Through bounding box, to perform SAM and achieve segmentation.
- Throgh a lower resolution vector dataset coming from another model, in an attempt to improve segmentation.
Tools
- 🦆 The program leverages Spatial-SQL DuckDB queries for precise vector operations
- ⚡ Image pyramids have been optimized via concurrency to GDAL-warping
- 📷 Integration of virtual layers through GDAL to SAMGeo
- 📄 MKDocs for automated docs+ jupyter visualization
Instructions
The entry points of the system are the following environment variables:
- TEXT_PROMPT: a string with the prompt to look for via Grounding DINO
- VECTOR_DATASET: a vector dataset
- DATA_DIR: location of the data
- BASE_DIR: where this package is located, acessible for deployments
- NAME_ORTOFOTO: basename for the image to be processed
Installation
In order to install this package, please download the yaml file in order to create the environment:
-
✅ If CUDA is available:
conda env create -f environment_cuda.yaml conda activate sam_apb_env pip install apb_spatial_computer_vision -
❌ If CUDA is not available:
conda env create -f environment_cpu.yaml conda activate sam_apb_env pip install apb_spatial_computer_vision
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file apb_spatial_computer_vision-1.1.0.tar.gz.
File metadata
- Download URL: apb_spatial_computer_vision-1.1.0.tar.gz
- Upload date:
- Size: 42.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e2fabb5a1e4a6e9e843d04df38875d45bc7a5ad6d8d467138f3a8898e63586f
|
|
| MD5 |
9874320fa99bab9c0d08af0d14de8c72
|
|
| BLAKE2b-256 |
d12c46f256bf8e459c8fea1f82871cc28eda23563ab76411768132a69328f911
|
File details
Details for the file apb_spatial_computer_vision-1.1.0-py3-none-any.whl.
File metadata
- Download URL: apb_spatial_computer_vision-1.1.0-py3-none-any.whl
- Upload date:
- Size: 50.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dddbfcc227f14857d355d338e1fbd6e7daa162f2ceb5e701dadbf3c293b34057
|
|
| MD5 |
2378b7756d762868c3840306ecfd4261
|
|
| BLAKE2b-256 |
599e5e6ff35caede4c6ea5512b72c5fcca5c255276544d5ae51d4b3bf46e9cea
|