NCAR/ccpp-framework

ccpp_prebuild: bug fix needed to provide backward compatibility with blocked data structures

Closed this issue · 0 comments

Description

I discovered a bug in the recently introduced support for chunked arrays in ccpp_prebuild.py when I started implementing chunked arrays in the UFS on a DDT-per-DDT basis. In order for chunked arrays and blocked data structures to peacefully coexist, we need to check if the host model variable is a contiguous array (it's horizontal dimension is CCPP_HORIZONTAL_DIMENSION) or part of a blocked data structure (it's horizontal dimension is CCPP_HORIZONTAL_LOOP_EXTENT).

Steps to Reproduce

Not that easy. Start by converting one GFS DDTs from a blocked data structure to chunked arrays and you will hit the problem that the framework doesn't handle the two different types of DDTs correctly.

Additional Context

n/a