Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
ece7b47f
Commit
ece7b47f
authored
Jun 15, 2018
by
Philipp Arras
Browse files
More renamings
parent
1bd43e72
Pipeline
#31070
passed with stages
in 1 minute and 24 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
nifty4/models/__init__.py
View file @
ece7b47f
from
.constant
import
Constant
Model
from
.constant
import
Constant
from
.local_nonlinearity
import
LocalModel
from
.model
import
LinearModel
,
Model
from
.
position
import
PositionModel
from
.
variable
import
Variable
__all__
=
[
'Model'
,
'Constant
Model
'
,
'LocalModel'
,
'
PositionModel
'
,
__all__
=
[
'Model'
,
'Constant'
,
'LocalModel'
,
'
Variable
'
,
'LinearModel'
]
nifty4/models/constant.py
View file @
ece7b47f
...
...
@@ -2,9 +2,9 @@ from ..operators import MultiSkyGradientOperator
from
.model
import
Model
class
Constant
Model
(
Model
):
class
Constant
(
Model
):
def
__init__
(
self
,
position
,
constant
):
super
(
Constant
Model
,
self
).
__init__
(
position
)
super
(
Constant
,
self
).
__init__
(
position
)
self
.
_constant
=
constant
self
.
_value
=
self
.
_constant
...
...
nifty4/models/
position
.py
→
nifty4/models/
variable
.py
View file @
ece7b47f
...
...
@@ -3,12 +3,12 @@ import nifty4 as ift
from
.model
import
Model
class
PositionModel
(
Model
):
class
Variable
(
Model
):
"""
Returns the MultiField.
"""
def
__init__
(
self
,
position
):
super
(
PositionModel
,
self
).
__init__
(
position
)
super
(
Variable
,
self
).
__init__
(
position
)
self
.
_value
=
position
self
.
_gradient
=
ift
.
ScalingOperator
(
1.
,
position
.
domain
)
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment