Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CardMech
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Harbor Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
KIT
Mpp
CardMech
Commits
98513c53
Commit
98513c53
authored
2 years ago
by
jonathan.froehlich
Browse files
Options
Downloads
Patches
Plain Diff
Updated geomtery conversion
parent
c5e8eac6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!219
Resolve "Add Excitation to Biventricle"
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
mpp
+1
-1
1 addition, 1 deletion
mpp
tools/geometries/vtu/ConvertCardiacVtu.cpp
+20
-6
20 additions, 6 deletions
tools/geometries/vtu/ConvertCardiacVtu.cpp
with
21 additions
and
7 deletions
mpp
@
13903933
Compare
a3c49681
...
13903933
Subproject commit
a3c4968126e0655272d3b44dc5be15309eaa3c8d
Subproject commit
139039331c6ac7e937b8030e699dfa31310d132f
This diff is collapsed.
Click to expand it.
tools/geometries/vtu/ConvertCardiacVtu.cpp
+
20
−
6
View file @
98513c53
...
...
@@ -59,7 +59,8 @@ int main(int argc, char **argv) {
return
0
;
}
std
::
string
geometryFile
=
loadFile
(
argv
[
1
]);
std
::
string
filename
(
argv
[
1
]);
std
::
string
geometryFile
=
loadFile
(
"tools/geometries/vtk/"
+
filename
+
".vtu"
);
std
::
string
confName
=
"default"
;
strcpy
(
argv
[
1
],
confName
.
c_str
());
...
...
@@ -68,20 +69,33 @@ int main(int argc, char **argv) {
Config
::
SetConfigFileName
(
"default.conf"
);
Mpp
::
initialize
(
&
argc
,
argv
);
auto
lvPoints
=
pointsFromFile
(
Config
::
GetConfPath
()
+
"../vtk/KovachevaBiventricleLV.csv"
);
auto
rvPoints
=
pointsFromFile
(
Config
::
GetConfPath
()
+
"../vtk/KovachevaBiventricleRV.csv"
);
auto
outerPoints
=
pointsFromFile
(
Config
::
GetConfPath
()
+
"../vtk/KovachevaBiventricleOuter.csv"
);
auto
lvPoints
=
pointsFromFile
(
std
::
string
(
ProjectSourceDir
)
+
"/tools/geometries/vtk/"
+
filename
+
"LV.csv"
);
auto
rvPoints
=
pointsFromFile
(
std
::
string
(
ProjectSourceDir
)
+
"/tools/geometries/vtk/"
+
filename
+
"RV.csv"
);
auto
outerPoints
=
pointsFromFile
(
std
::
string
(
ProjectSourceDir
)
+
"/tools/geometries/vtk/"
+
filename
+
"Outer.csv"
);
VtuConverter
converter
(
geometryFile
);
const
auto
&
M
=
converter
.
UseCellArrayAsSubdomain
(
0
)
.
UseArrayForCellData
(
1
)
.
UseArrayForCellData
(
2
)
.
UseArrayForCellData
(
3
)
//
.WithExcitationFromFile(0, 0.003, 30.0)
.
WithExcitationFromFile
(
0
,
0.003
,
30.0
)
.
WithBoundaryFromData
({
230
,
230
},
std
::
move
(
lvPoints
))
.
WithBoundaryFromData
({
231
,
231
},
std
::
move
(
rvPoints
))
.
WithBoundaryFromData
({
330
,
199
},
std
::
move
(
outerPoints
))
.
WithBoundaryFromData
({
330
,
331
},
std
::
move
(
outerPoints
))
.
WithBoundarySmoothing
({
199
,
330
,
331
})
.
WithSubdomainConversion
([](
int
sd
)
{
switch
(
sd
)
{
case
30
:
return
1000
;
case
31
:
return
0
;
default:
return
(
sd
-
30
)
*
1000
;
}
})
.
Create
();
smoothMeshData
(
M
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment