GiDInterface icon indicating copy to clipboard operation
GiDInterface copied to clipboard

[GiD model] Submodel part naming conflict

Open mpentek opened this issue 5 years ago • 13 comments

When working with multiple geometry layers and groups for better handling of complex geometry, I have the following situation: image So I will end up with submodel parts when using Kratos with names such as: FluidModelPart.Drag_mq/1 which is internally used for output (file) generation. I find the choice of the "/" as subgroup/child separator not the best choice. Was this intended to be like this, does it have to be like this? Is it something that comes from the Kratos problemtype? @rubenzorrilla I assume that a lot of processes might encounter errors due to special character such as "/" included in names.

mpentek avatar Jan 20 '20 15:01 mpentek

Honestly, I have never used subgroups so far... In any case I agree that the slash is not the best character.

@jginternational can we control this?

rubenzorrilla avatar Jan 21 '20 17:01 rubenzorrilla

From the 'kratos point of view' there are no groups, we'll have submodelparts

You are right -> The name of the submodelparts whose group is child is written like this: "FluidModelPart.Outlet2D_Outlet/Child" Maybe we can change it to this if we don't like the / as separator: "FluidModelPart.Outlet2D_Outlet-Child"

Spaces are changed for underscores _ Child slashes could be replaced for regular score -

jginternational avatar Jan 21 '20 19:01 jginternational

FluidModelPart.Outlet2D_Outlet-Child sounds good to me :+1: , it should work

philbucher avatar Jan 22 '20 09:01 philbucher

The - is fine for me as well.

However, I think that the subgroups in GiD (1, 2, 3, 4 and 5 in @mpentek snapshot) should be subsubmodelparts in the *.mdpa. Is this possible @jginternational ?

rubenzorrilla avatar Jan 22 '20 16:01 rubenzorrilla

Nope @rubenzorrilla A submodelpart is created in the join of a Condition (on the problemtype) with a group example: If I assign a group to an Inlet I'll have the submodelpart Inlet_group If I assign a group to an Inlet twice (same group, different time intervals) I'll have only 1 submodelpart Inlet_group

If I assign a subgroup group//subgroup to an inlet, the submodelpart created is expected to be Inlet_group-subgroup

  • I hate the polysemy of the word Condition

jginternational avatar Jan 22 '20 17:01 jginternational

For me the main concern for now is the format, meaning avoiding separators which are generally used for folder path and so on. If this were to be changed from "/" to "-", would it cause problems with compatibility, tests and so on @jginternational? I think it would by anyway worth it in the long run.

The discussion of model/submodel/subsubmodel is perhaps another aspect. Here @rubenzorrilla and @philbucher can say more.

mpentek avatar Jan 23 '20 10:01 mpentek

@mpentek I'm merging that branch soon if there are no problems!

jginternational avatar Mar 27 '20 19:03 jginternational

Re-opening this issue, as with the most current setup (Win10 + GiD15.0.1 + Kratos GiD problemtype - from here) I have the same ongoing issue: the naming will be with "/" or "//".

Am I missing something? I had the impression this was changed.

mpentek avatar Nov 24 '20 08:11 mpentek

@jginternational can you please comment if this is solved? This breaks many outputs in Kratos!

philbucher avatar Nov 25 '20 08:11 philbucher

sorry. The requested changes have been pushed to master after checking all the tests.

I though I wrote this yesterday, but it seem that I forgot to click on the green button :(

jginternational avatar Nov 25 '20 08:11 jginternational

coolt thx!

philbucher avatar Nov 25 '20 09:11 philbucher

Hi, Is there a way to avoid using "-" when naming model parts, submodel parts when used with groups? Because hdf5 cannot write names with "-" (no idea why tho). @jginternational . These "-" are automatically generated when you have groups within groups :/

sunethwarna avatar Jun 02 '21 15:06 sunethwarna

"-" was the proposal to get away from "//", which was conflicting with path separators.

mpentek avatar Jun 02 '21 15:06 mpentek