Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Core] Geometries to entities modeler #11370

Merged
merged 36 commits into from
Oct 4, 2023
Merged
Changes from 2 commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
a3c9e13
Merge branch 'core/model-part-io-geometries-fix' into core/geometries…
rubenzorrilla Jul 6, 2023
22bf135
Preliminary implementation (working on it)
rubenzorrilla Jul 6, 2023
f4239a5
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Jul 7, 2023
1ffea05
Working version with test
rubenzorrilla Jul 7, 2023
c1bb3f1
Merge branch 'master' into core/geometries-to-entities-modeler
loumalouomega Jul 10, 2023
b8d8192
Applying intermediate comments
loumalouomega Jul 10, 2023
3ec860a
Moving to source file
loumalouomega Jul 10, 2023
936d8c8
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Jul 24, 2023
02783b8
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Jul 31, 2023
11e0232
Geometries PrintData minor improvement
rubenzorrilla Aug 1, 2023
0b7e75e
Minors in entities utilities
rubenzorrilla Aug 1, 2023
344b056
Minor advances (mixed not working)
rubenzorrilla Aug 1, 2023
5b7fe76
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Aug 9, 2023
2046af2
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Aug 30, 2023
f533030
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Aug 31, 2023
38f1950
Adding HasPrototypeEntity
rubenzorrilla Sep 1, 2023
36bc13d
Working version
rubenzorrilla Sep 1, 2023
38717be
Merge branch 'core/entities-utilities-has-entity' into core/geometrie…
rubenzorrilla Sep 1, 2023
ba08fec
Remove undesired changes
rubenzorrilla Sep 1, 2023
2cc9c6d
Merge branch 'core/entities-utilities-has-entity' into core/geometrie…
rubenzorrilla Sep 1, 2023
42e5f2f
Merge branch 'core/geometries-to-entities-modeler' of https://github.…
rubenzorrilla Sep 5, 2023
54c2347
Merge branch 'core/geometries-print-data-minor-improvements' into cor…
rubenzorrilla Sep 5, 2023
f5a3ea2
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Sep 5, 2023
251c865
More robust type check
rubenzorrilla Sep 5, 2023
21ede17
Add to registry
rubenzorrilla Sep 6, 2023
604a4d9
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Sep 21, 2023
097ce9a
Update registry macro
rubenzorrilla Sep 21, 2023
0f08fab
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Oct 2, 2023
2d43044
Merge branch 'core/geometries-to-entities-modeler' of https://github.…
rubenzorrilla Oct 2, 2023
bc2c578
KratosCore minors
rubenzorrilla Oct 2, 2023
d30143c
Deprecating old modelers factory
rubenzorrilla Oct 2, 2023
70234b2
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Oct 2, 2023
aa35d1d
Backwards compatible modelers creation
rubenzorrilla Oct 2, 2023
54b6bfb
Update kratos/python_scripts/analysis_stage.py
rubenzorrilla Oct 3, 2023
a26755f
Merge branch 'master' into core/geometries-to-entities-modeler
rubenzorrilla Oct 3, 2023
4aa9245
Avoid template specialization
rubenzorrilla Oct 3, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 17 additions & 4 deletions kratos/python_scripts/analysis_stage.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,8 @@ def _GetListOfModelers(self):
def _CreateModelers(self):
""" List of modelers in following format:
"modelers" : [{
"modeler_name" : "geometry_import",
"Parameters" : {
"name" : "geometry_import",
"parameters" : {
"echo_level" : 0,
// settings for this modeler
}
Expand All @@ -307,9 +307,22 @@ def _CreateModelers(self):
self._list_of_modelers = []

if self.project_parameters.Has("modelers"):
factory = KratosModelParametersFactory(self.model)
modelers_list = self.project_parameters["modelers"]
self._list_of_modelers = factory.ConstructListOfItems(modelers_list)
#TODO: Remove this after the deprecation period
if self.__BackwardCompatibleModelersCreation(modelers_list):
from KratosMultiphysics.modeler_factory import KratosModelerFactory
factory = KratosModelerFactory()
self._list_of_modelers = factory.ConstructListOfModelers(self.model, modelers_list)
else:
factory = KratosModelParametersFactory(self.model)
self._list_of_modelers = factory.ConstructListOfItems(modelers_list)

@classmethod
def __BackwardCompatibleModelersCreation(self, modelers_list):
for modeler in modelers_list:
if modeler.Has("modeler_name"):
return True
return False
rubenzorrilla marked this conversation as resolved.
Show resolved Hide resolved

### Processes
def _GetListOfProcesses(self):
Expand Down
Loading