Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
dolfin_dic
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
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
BERBEROGLU Ezgi
dolfin_dic
Commits
1a02a9c4
Commit
1a02a9c4
authored
5 years ago
by
Martin Genet
Browse files
Options
Downloads
Patches
Plain Diff
Box structure now works in any dimension
parent
18bfe39e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
generate_images_Image.py
+9
-3
9 additions, 3 deletions
generate_images_Image.py
with
9 additions
and
3 deletions
generate_images_Image.py
+
9
−
3
View file @
1a02a9c4
...
...
@@ -24,7 +24,13 @@ import dolfin_dic as ddic
class
Image
():
def
__init__
(
self
,
images
,
structure
,
texture
,
noise
,
generate_image_gradient
=
False
):
def
__init__
(
self
,
images
,
structure
,
texture
,
noise
,
generate_image_gradient
=
False
):
self
.
L
=
images
[
"
L
"
]
...
...
@@ -33,8 +39,8 @@ class Image():
self
.
I0_structure
=
self
.
I0_structure_no_wGrad
if
(
generate_image_gradient
)
else
self
.
I0_structure_no
elif
(
structure
[
"
type
"
]
==
"
box
"
):
self
.
I0_structure
=
self
.
I0_structure_box_wGrad
if
(
generate_image_gradient
)
else
self
.
I0_structure_box
self
.
Xmin
=
structure
[
"
Xmin
"
]
self
.
Xmax
=
structure
[
"
Xmax
"
]
self
.
Xmin
=
structure
[
"
Xmin
"
]
+
[
float
(
"
-Inf
"
)]
*
(
3
-
images
[
"
n_dim
"
])
self
.
Xmax
=
structure
[
"
Xmax
"
]
+
[
float
(
"
+Inf
"
)]
*
(
3
-
images
[
"
n_dim
"
])
elif
(
structure
[
"
type
"
]
==
"
heart
"
):
if
(
images
[
"
n_dim
"
]
==
2
):
self
.
I0_structure
=
self
.
I0_structure_heart_2_wGrad
if
(
generate_image_gradient
)
else
self
.
I0_structure_heart_2
...
...
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