-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
benchmark-failureintegration test failedintegration test failed
Description
Benchmark scenario ID: phenology
Benchmark scenario definition: https://github.com/ESA-APEx/apex_algorithms/blob/df1831b072f3ccf01c57bfed4405189df2c29602/algorithm_catalog/vito/phenology/benchmark_scenarios/phenology.json
openEO backend: openeofed.dataspace.copernicus.eu
GitHub Actions workflow run: https://github.com/ESA-APEx/apex_algorithms/actions/runs/20461821428
Workflow artifacts: https://github.com/ESA-APEx/apex_algorithms/actions/runs/20461821428#artifacts
Test start: 2025-12-23 13:20:20.953560+00:00
Test duration: 0:06:01.365769
Test outcome: ❌ failed
Last successful test phase: download-reference
Failure in test phase: compare
Contact Information
| Name | Organization | Contact |
|---|---|---|
| Bram Janssen | VITO | Contact via VITO (VITO Website, GitHub) |
Process Graph
{
"phenology1": {
"arguments": {
"spatial_extent": {
"coordinates": [
[
[
5.179169745059369,
51.24984286550534
],
[
5.170016107999743,
51.25052999567865
],
[
5.171081610725707,
51.24861004739975
],
[
5.178604705735125,
51.246720335821465
],
[
5.179169745059369,
51.24984286550534
]
]
],
"type": "Polygon"
},
"temporal_extent": [
"2022-05-01",
"2022-09-30"
]
},
"namespace": "https://raw.githubusercontent.com/VITObelgium/openeo_algorithm_catalog/refs/heads/main/phenology/openeo_udp/phenology.json",
"process_id": "phenology"
},
"saveresult1": {
"arguments": {
"data": {
"from_node": "phenology1"
},
"format": "GTiff",
"options": {}
},
"process_id": "save_result",
"result": true
}
}Error Logs
scenario = BenchmarkScenario(id='phenology', description='Computes phenology metrics based on the Phenolopy implementation on NDV...home/runner/work/apex_algorithms/apex_algorithms/algorithm_catalog/vito/phenology/benchmark_scenarios/phenology.json'))
connection_factory = <function connection_factory.<locals>.get_connection at 0x7f0dbf704cc0>
tmp_path = PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0')
track_metric = <function track_metric.<locals>.track at 0x7f0dbf704d60>
track_phase = <function track_phase.<locals>.track at 0x7f0dbf704fe0>
upload_assets_on_fail = <function upload_assets_on_fail.<locals>.collect at 0x7f0dbf705080>
request = <FixtureRequest for <Function test_run_benchmark[phenology]>>
@pytest.mark.parametrize(
"scenario",
[
# Use scenario id as parameterization id to give nicer test names.
pytest.param(uc, id=uc.id)
for uc in get_benchmark_scenarios()
],
)
def test_run_benchmark(
scenario: BenchmarkScenario,
connection_factory,
tmp_path: Path,
track_metric,
track_phase,
upload_assets_on_fail,
request,
):
track_metric("scenario_id", scenario.id)
with track_phase(phase="connect"):
# Check if a backend override has been provided via cli options.
override_backend = request.config.getoption("--override-backend")
backend_filter = request.config.getoption("--backend-filter")
if backend_filter and not re.match(backend_filter, scenario.backend):
# TODO apply filter during scenario retrieval, but seems to be hard to retrieve cli param
pytest.skip(
f"skipping scenario {scenario.id} because backend {scenario.backend} does not match filter {backend_filter!r}"
)
backend = scenario.backend
if override_backend:
_log.info(f"Overriding backend URL with {override_backend!r}")
backend = override_backend
connection: openeo.Connection = connection_factory(url=backend)
with track_phase(phase="create-job"):
# TODO #14 scenario option to use synchronous instead of batch job mode?
job = connection.create_job(
process_graph=scenario.process_graph,
title=f"APEx benchmark {scenario.id}",
additional=scenario.job_options,
)
track_metric("job_id", job.job_id)
with track_phase(phase="run-job"):
# TODO: monitor timing and progress
# TODO: abort excessively long batch jobs? https://github.com/Open-EO/openeo-python-client/issues/589
job.start_and_wait()
# TODO: separate "job started" and run phases?
with track_phase(phase="collect-metadata"):
collect_metrics_from_job_metadata(job, track_metric=track_metric)
results = job.get_results()
collect_metrics_from_results_metadata(results, track_metric=track_metric)
with track_phase(phase="download-actual"):
# Download actual results
actual_dir = tmp_path / "actual"
paths = results.download_files(target=actual_dir, include_stac_metadata=True)
# Upload assets on failure
upload_assets_on_fail(*paths)
with track_phase(phase="download-reference"):
reference_dir = download_reference_data(
scenario=scenario, reference_dir=tmp_path / "reference"
)
with track_phase(
phase="compare", describe_exception=analyse_results_comparison_exception
):
# Compare actual results with reference data
> assert_job_results_allclose(
actual=actual_dir,
expected=reference_dir,
tmp_path=tmp_path,
rtol=scenario.reference_options.get("rtol", 1e-6),
atol=scenario.reference_options.get("atol", 1e-6),
pixel_tolerance=scenario.reference_options.get("pixel_tolerance", 0.0),
)
tests/test_benchmarks.py:95:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
actual = PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/actual')
expected = PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference')
def assert_job_results_allclose(
actual: Union[BatchJob, JobResults, str, Path],
expected: Union[BatchJob, JobResults, str, Path],
*,
rtol: float = _DEFAULT_RTOL,
atol: float = _DEFAULT_ATOL,
pixel_tolerance: float = _DEFAULT_PIXELTOL,
tmp_path: Optional[Path] = None,
):
"""
Assert that two job results sets are equal (with tolerance).
:param actual: actual job results, provided as :py:class:`~openeo.rest.job.BatchJob` object,
:py:meth:`~openeo.rest.job.JobResults` object or path to directory with downloaded assets.
:param expected: expected job results, provided as :py:class:`~openeo.rest.job.BatchJob` object,
:py:meth:`~openeo.rest.job.JobResults` object or path to directory with downloaded assets.
:param rtol: relative tolerance
:param atol: absolute tolerance
:param pixel_tolerance: maximum fraction of pixels (in percent)
that is allowed to be significantly different (considering ``atol`` and ``rtol``)
:param tmp_path: root temp path to download results if needed.
It's recommended to pass pytest's `tmp_path` fixture here
:raises AssertionError: if not equal within the given tolerance
.. versionadded:: 0.31.0
.. warning::
This function is experimental and subject to change.
"""
issues = _compare_job_results(
actual, expected, rtol=rtol, atol=atol, pixel_tolerance=pixel_tolerance, tmp_path=tmp_path
)
if issues:
> raise AssertionError("\n".join(issues))
E AssertionError: File set mismatch: {'job-results.json', 'openEO_2022-05-02Z.tif'} != {'timeseries.json', 'job-results.json'}
/opt/hostedtoolcache/Python/3.12.12/x64/lib/python3.12/site-packages/openeo/testing/results.py:515: AssertionError
----------------------------- Captured stdout call -----------------------------
0:00:00 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': send 'start'
0:00:15 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': created (progress 0%)
0:00:21 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': created (progress 0%)
0:00:27 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': created (progress 0%)
0:00:36 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': created (progress 0%)
0:00:46 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:00:59 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:01:14 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:01:34 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:01:58 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:02:28 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:03:05 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:03:52 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:04:51 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': running (progress N/A)
0:05:51 Job 'cdse-j-25122313202440f996b9bf59baf4f5c3': finished (progress 100%)
------------------------------ Captured log call -------------------------------
INFO conftest:conftest.py:131 Connecting to 'openeofed.dataspace.copernicus.eu'
INFO openeo.config:config.py:193 Loaded openEO client config from sources: []
INFO conftest:conftest.py:144 Checking for auth_env_var='OPENEO_AUTH_CLIENT_CREDENTIALS_CDSEFED' to drive auth against url='openeofed.dataspace.copernicus.eu'.
INFO conftest:conftest.py:148 Extracted provider_id='CDSE' client_id='openeo-apex-benchmarks-service-account' from auth_env_var='OPENEO_AUTH_CLIENT_CREDENTIALS_CDSEFED'
INFO openeo.rest.connection:connection.py:260 Found OIDC providers: ['CDSE']
INFO openeo.rest.auth.oidc:oidc.py:404 Doing 'client_credentials' token request 'https://identity.dataspace.copernicus.eu/auth/realms/CDSE/protocol/openid-connect/token' with post data fields ['grant_type', 'client_id', 'client_secret', 'scope'] (client_id 'openeo-apex-benchmarks-service-account')
INFO openeo.rest.connection:connection.py:359 Obtained tokens: ['access_token', 'id_token']
INFO openeo.rest.job:job.py:436 Downloading Job result asset 'openEO_2022-05-02Z.tif' from https://s3.waw3-1.openeo.v1.dataspace.copernicus.eu/openeo-data-prod-waw4-1/batch_jobs/j-25122313202440f996b9bf59baf4f5c3/openEO_2022-05-02Z.tif?X-Proxy-Head-As-Get=true&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=36f4082b8b2441fb83897187862288f4%2F20251223%2Fwaw4-1%2Fs3%2Faws4_request&X-Amz-Date=20251223T132617Z&X-Amz-Expires=86400&X-Amz-SignedHeaders=host&X-Amz-Security-Token=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJyb2xlX2FybiI6ImFybjpvcGVuZW93czppYW06Ojpyb2xlL29wZW5lby1kYXRhLXByb2Qtd2F3NC0xLXdvcmtzcGFjZSIsImluaXRpYWxfaXNzdWVyIjoib3BlbmVvLnByb2Qud2F3My0xLm9wZW5lby1pbnQudjEuZGF0YXNwYWNlLmNvcGVybmljdXMuZXUiLCJodHRwczovL2F3cy5hbWF6b24uY29tL3RhZ3MiOnsicHJpbmNpcGFsX3RhZ3MiOnsiam9iX2lkIjpbImotMjUxMjIzMTMyMDI0NDBmOTk2YjliZjU5YmFmNGY1YzMiXSwidXNlcl9pZCI6WyI2YTc3ZmNkMS05YzA4LTQ2ZTktYjg3NS01NGZiOTk5YWIyMDAiXX0sInRyYW5zaXRpdmVfdGFnX2tleXMiOlsidXNlcl9pZCIsImpvYl9pZCJdfSwiaXNzIjoic3RzLndhdzMtMS5vcGVuZW8udjEuZGF0YXNwYWNlLmNvcGVybmljdXMuZXUiLCJzdWIiOiJvcGVuZW8tZHJpdmVyIiwiZXhwIjoxNzY2NTM5NTc3LCJuYmYiOjE3NjY0OTYzNzcsImlhdCI6MTc2NjQ5NjM3NywianRpIjoiYzBiODE3NGItNTg1YS00OWNjLWFlZmQtMmNhNzExZmNiZTEyIiwiYWNjZXNzX2tleV9pZCI6IjM2ZjQwODJiOGIyNDQxZmI4Mzg5NzE4Nzg2MjI4OGY0In0.SOGCQd9M14yjg0R5L8CVySmDwVDR9RNiMLslpxXAa0u1HXkII090F90ozg5RikwaAb-n3oYcv2vwgfeJtI-VxzSx4KD_Ui_MqQ0AXa84lsENLhhXt1lkwlb34bYkU1Yab9ZfMPCeLmzhtJ-ACM8ZMdSxek4DwjnRENdfqfVllWCV_5m7A0zasaKOMJ3ldOpfJ6aJmL6vi-tXEDMsGeeLfCTbtnR_fDEWcttmijGSxoKdcoSj8WzMVM8HpEXCul9U4jb2lT1nTpXeo2ixJNx3WnRkhgX6tjSVPWjqp1Pi2i448ceLkgUeVand80YWM30q9ZaB6khtGc-tiuAnCWwVDg&X-Amz-Signature=bead7eadad4ef32e6b9d4917570f295361fe11a16e0d6b83c62e7ee1decbbe19 to /home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/actual/openEO_2022-05-02Z.tif
INFO apex_algorithm_qa_tools.scenarios:util.py:345 Downloading reference data for scenario.id='phenology' to reference_dir=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference'): start 2025-12-23 13:26:20.676242
INFO apex_algorithm_qa_tools.scenarios:util.py:345 Downloading source='https://s3.waw3-1.cloudferro.com/swift/v1/apex-examples/phenology/openEO.tif' to path=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference/timeseries.json'): start 2025-12-23 13:26:20.676568
INFO apex_algorithm_qa_tools.scenarios:util.py:351 Downloading source='https://s3.waw3-1.cloudferro.com/swift/v1/apex-examples/phenology/openEO.tif' to path=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference/timeseries.json'): end 2025-12-23 13:26:21.487172, elapsed 0:00:00.810604
INFO apex_algorithm_qa_tools.scenarios:util.py:345 Downloading source='https://s3.waw3-1.cloudferro.com/swift/v1/apex-examples/phenology/job-results.json' to path=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference/job-results.json'): start 2025-12-23 13:26:21.487510
INFO apex_algorithm_qa_tools.scenarios:util.py:351 Downloading source='https://s3.waw3-1.cloudferro.com/swift/v1/apex-examples/phenology/job-results.json' to path=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference/job-results.json'): end 2025-12-23 13:26:22.316335, elapsed 0:00:00.828825
INFO apex_algorithm_qa_tools.scenarios:util.py:351 Downloading reference data for scenario.id='phenology' to reference_dir=PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference'): end 2025-12-23 13:26:22.316539, elapsed 0:00:01.640297
INFO openeo.testing.results:results.py:418 Comparing job results: PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/actual') vs PosixPath('/home/runner/work/apex_algorithms/apex_algorithms/qa/benchmarks/tmp_path_root/test_run_benchmark_phenology_0/reference')
Metadata
Metadata
Assignees
Labels
benchmark-failureintegration test failedintegration test failed