Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
TurTLE
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TurTLE
TurTLE
Commits
d759c7ef
Commit
d759c7ef
authored
8 years ago
by
Chichi Lalescu
Browse files
Options
Downloads
Patches
Plain Diff
update test
parent
be5cb422
No related branches found
No related tags found
2 merge requests
!21
Bugfix/nansampling
,
!3
Bugfix/event manager show html
Changes
4
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
bfps/__init__.py
+1
-0
1 addition, 0 deletions
bfps/__init__.py
bfps/_base.py
+0
-8
0 additions, 8 deletions
bfps/_base.py
bfps/_fluid_base.py
+1
-1
1 addition, 1 deletion
bfps/_fluid_base.py
tests/test_vorticity_equation.py
+19
-1195
19 additions, 1195 deletions
tests/test_vorticity_equation.py
with
21 additions
and
1204 deletions
bfps/__init__.py
+
1
−
0
View file @
d759c7ef
...
@@ -49,4 +49,5 @@ from host_information import host_info
...
@@ -49,4 +49,5 @@ from host_information import host_info
from
.FluidConvert
import
FluidConvert
from
.FluidConvert
import
FluidConvert
from
.FluidResize
import
FluidResize
from
.FluidResize
import
FluidResize
from
.NavierStokes
import
NavierStokes
from
.NavierStokes
import
NavierStokes
from
.NSVorticityEquation
import
NSVorticityEquation
This diff is collapsed.
Click to expand it.
bfps/_base.py
+
0
−
8
View file @
d759c7ef
...
@@ -83,7 +83,6 @@ class _base(object):
...
@@ -83,7 +83,6 @@ class _base(object):
'
hid_t dset, memtype, space;
\n
'
+
'
hid_t dset, memtype, space;
\n
'
+
'
char fname[256];
\n
'
+
'
char fname[256];
\n
'
+
'
hsize_t dims[1];
\n
'
+
'
hsize_t dims[1];
\n
'
+
#'char *string_data;\n' +
'
char string_data[512];
\n
'
+
'
char string_data[512];
\n
'
+
'
sprintf(fname,
"
%s.h5
"
, simname);
\n
'
+
'
sprintf(fname,
"
%s.h5
"
, simname);
\n
'
+
'
parameter_file = H5Fopen(fname, H5F_ACC_RDONLY, H5P_DEFAULT);
\n
'
)
'
parameter_file = H5Fopen(fname, H5F_ACC_RDONLY, H5P_DEFAULT);
\n
'
)
...
@@ -95,15 +94,8 @@ class _base(object):
...
@@ -95,15 +94,8 @@ class _base(object):
elif
type
(
parameters
[
key
[
i
]])
==
str
:
elif
type
(
parameters
[
key
[
i
]])
==
str
:
src_txt
+=
(
'
space = H5Dget_space(dset);
\n
'
+
src_txt
+=
(
'
space = H5Dget_space(dset);
\n
'
+
'
memtype = H5Dget_type(dset);
\n
'
+
'
memtype = H5Dget_type(dset);
\n
'
+
#'H5Sget_simple_extent_dims(space, dims, NULL);\n' +
#'DEBUG_MSG("dims[0] = %ld\\n", dims[0]);\n' +
#'string_data = (char*)malloc(512*sizeof(char));\n' +
#'string_data = new char[512];\n' +
'
H5Dread(dset, memtype, H5S_ALL, H5S_ALL, H5P_DEFAULT, &string_data);
\n
'
+
'
H5Dread(dset, memtype, H5S_ALL, H5S_ALL, H5P_DEFAULT, &string_data);
\n
'
+
'
sprintf({0},
"
%s
"
, string_data);
\n
'
.
format
(
key
[
i
])
+
'
sprintf({0},
"
%s
"
, string_data);
\n
'
.
format
(
key
[
i
])
+
#'DEBUG_MSG("{0} = %s\\n", {0});\n'.format(key[i]) +
#'delete[] string_data;\n' +
#'free(string_data);\n'
'
H5Sclose(space);
\n
'
+
'
H5Sclose(space);
\n
'
+
'
H5Tclose(memtype);
\n
'
)
'
H5Tclose(memtype);
\n
'
)
elif
type
(
parameters
[
key
[
i
]])
==
np
.
ndarray
:
elif
type
(
parameters
[
key
[
i
]])
==
np
.
ndarray
:
...
...
This diff is collapsed.
Click to expand it.
bfps/_fluid_base.py
+
1
−
1
View file @
d759c7ef
...
@@ -417,7 +417,7 @@ class _fluid_particle_base(_code):
...
@@ -417,7 +417,7 @@ class _fluid_particle_base(_code):
Kdata0
,
Kdata0
,
self
.
parameters
[
'
nz
'
],
self
.
parameters
[
'
nz
'
],
self
.
parameters
[
'
ny
'
],
self
.
parameters
[
'
ny
'
],
self
.
parameters
[
'
nx
'
])
self
.
parameters
[
'
nx
'
])
.
copy
()
if
write_to_file
:
if
write_to_file
:
Kdata1
.
tofile
(
Kdata1
.
tofile
(
os
.
path
.
join
(
self
.
work_dir
,
os
.
path
.
join
(
self
.
work_dir
,
...
...
This diff is collapsed.
Click to expand it.
tests/test_vorticity_equation.py
+
19
−
1195
View file @
d759c7ef
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