File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change 5
5
### Added
6
6
7
7
- (Experimental) support for Python 3.10 ([ #473 ] ( https://github.com/stac-utils/pystac/pull/473 ) )
8
+ - ` LabelTask ` enum in ` pystac.extensions.label ` with recommended values for
9
+ ` "label:tasks" ` field ([ #484 ] ( https://github.com/stac-utils/pystac/pull/484 ) )
10
+ - ` LabelMethod ` enum in ` pystac.extensions.label ` with recommended values for
11
+ ` "label:methods" ` field ([ #484 ] ( https://github.com/stac-utils/pystac/pull/484 ) )
12
+ - Label Extension summaries ([ #484 ] ( https://github.com/stac-utils/pystac/pull/484 ) )
8
13
9
14
### Changed
10
15
Original file line number Diff line number Diff line change 10
10
LabelExtension ,
11
11
LabelClasses ,
12
12
LabelCount ,
13
+ LabelMethod ,
13
14
LabelOverview ,
14
15
LabelStatistics ,
15
16
LabelTask ,
@@ -522,3 +523,20 @@ def test_label_task_summary(self) -> None:
522
523
label_tasks_summary_ext = label_ext_summaries .label_tasks
523
524
assert label_tasks_summary_ext is not None
524
525
self .assertListEqual (label_tasks , label_tasks_summary_ext )
526
+
527
+ def test_label_methods_summary (self ) -> None :
528
+ label_methods : List [Union [LabelMethod , str ]] = [LabelMethod .AUTOMATED ]
529
+ collection = Collection .from_file (self .EXAMPLE_COLLECTION )
530
+ label_ext_summaries = LabelExtension .summaries (collection )
531
+
532
+ label_ext_summaries .label_methods = label_methods
533
+
534
+ summaries = collection .summaries
535
+ assert summaries is not None
536
+ label_methods_summary = summaries .get_list ("label:methods" )
537
+ assert label_methods_summary is not None
538
+ self .assertListEqual (label_methods , label_methods_summary )
539
+
540
+ label_methods_summary_ext = label_ext_summaries .label_methods
541
+ assert label_methods_summary_ext is not None
542
+ self .assertListEqual (label_methods , label_methods_summary_ext )
You can’t perform that action at this time.
0 commit comments