issue with poly2mask

9 vues (au cours des 30 derniers jours)
David Serke
David Serke le 11 Juil 2018
Modifié(e) : dpb le 11 Juil 2018
Hello, I am trying to find the intersection over union of two polygons using poly2mask and polyarea. My two polygons are defined by:
box_rad_actu_lons_5 =
-2.0943 -2.1058 -2.0754 -2.0640 -2.0943
box_rad_actu_lats_5 =
0.6282 0.6135 0.5973 0.6120 0.6282
box_rad_proj_lons_5 =
-2.0948 -2.1057 -2.0735 -2.0627 -2.0948
box_rad_proj_lats_5 =
0.6284 0.6134 0.5975 0.6125 0.6284
When I apply poly2mask, as follows:
box_actu = poly2mask(box_rad_actu_lons_5, box_rad_actu_lats_5, 1000, 1000);
box_proj = poly2mask(box_rad_proj_lons_5, box_rad_proj_lats_5, 1000, 1000);
The results are no pixels that are within the polygons (value =1) for either box. What am I doing wrong?
Thanks, Dave Serke

Réponses (0)

Catégories

En savoir plus sur Cell Arrays dans Help Center et File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by