Context
Following a discussion with @MathieuMorlighem (Nov 12 2025 AEST), we reviewed the relevance of InterpFromModel3dToMesh2d after commit 2f9c9c5, which ports the routine to Python.
Mathieu noted that this function was originally introduced before we had more robust tools like DepthAverage and project2d, and that it is currently unmaintained.
The consensus is that if equivalent workflows can be fully covered by these other utilities, the function can be deprecated and eventually removed.
Key points from the discussion
- I currently use the function for cases such as:
T3d = mdT.results.ThermalSolution.Temperature
T = InterpFromModel3dToMesh2d(mdT, T3d, md.mesh.x, md.mesh.y, np.nan, 253)
to map a 3-D HO temperature field onto a 2-D mesh.
-
Mathieu clarified that:
-
If the 3-D mesh is an extrusion of the same 2-D mesh, then no interpolation is required.
-
In that case, one should instead use:
md.initialization.temperature = DepthAverage(mdT, T3d)
or project2d if extracting a specific layer.
-
Therefore, InterpFromModel3dToMesh2d is redundant when:
- The 3-D model is an extruded version of the 2-D base mesh, and
- The goal is a vertical average or slice extraction.
Action plan
📁 References
Context
Following a discussion with @MathieuMorlighem (Nov 12 2025 AEST), we reviewed the relevance of
InterpFromModel3dToMesh2dafter commit 2f9c9c5, which ports the routine to Python.Mathieu noted that this function was originally introduced before we had more robust tools like
DepthAverageandproject2d, and that it is currently unmaintained.The consensus is that if equivalent workflows can be fully covered by these other utilities, the function can be deprecated and eventually removed.
Key points from the discussion
to map a 3-D HO temperature field onto a 2-D mesh.
Mathieu clarified that:
If the 3-D mesh is an extrusion of the same 2-D mesh, then no interpolation is required.
In that case, one should instead use:
or
project2dif extracting a specific layer.Therefore,
InterpFromModel3dToMesh2dis redundant when:Action plan
DepthAverageorproject2d, mark the function as deprecated and remove it after a grace period.📁 References
Commit: [2f9c9c5](ISSMteam@2f9c9c5)
Related files:
src/m/contrib/InterpFromModel3dToMesh2d.msrc/m/extrusion/DepthAverage.msrc/m/extrusion/project2d.m