pysdic.core.property_container.PropertyContainer.concatenate#

PropertyContainer.concatenate(other, *, fill=nan)[source]#

Concatenate two containers along the first dimension.

The resulting container has \(N_{self} + N_{other}\) entities:

  • a property present in both containers is concatenated (the attribute shapes must match),

  • a property present in only one container is completed with fill for the entities of the other container.

The data type of each property is promoted if needed to hold both the values and fill. For example, an integer property completed with numpy.nan becomes a float property.

The force_2d flag of the result is True only if it is True for both containers.

Parameters:
Returns:

A new container with the concatenated properties.

Return type:

pysdic.core.property_container.PropertyContainer

Raises:

ValueError – If a property present in both containers has different attribute shapes.