Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
NIFTy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
ift
NIFTy
Commits
0808fda1
There was a problem fetching the pipeline summary.
Commit
0808fda1
authored
7 years ago
by
Theo Steininger
Browse files
Options
Downloads
Patches
Plain Diff
Fixed default distribution_strategy in create_power_operator
parent
9dbf2577
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!174
Master
Pipeline
#
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
nifty/sugar.py
+9
-4
9 additions, 4 deletions
nifty/sugar.py
with
9 additions
and
4 deletions
nifty/sugar.py
+
9
−
4
View file @
0808fda1
...
...
@@ -19,13 +19,14 @@
from
nifty
import
PowerSpace
,
\
Field
,
\
DiagonalOperator
,
\
sqrt
from
nifty.minimization.conjugate_gradient
import
ConjugateGradient
__all__
=
[
'
create_power_operator
'
]
sqrt
,
\
nifty_configuration
__all__
=
[
'
create_power_operator
'
,
'
generate_posterior_sample
'
]
def
create_power_operator
(
domain
,
power_spectrum
,
dtype
=
None
,
distribution_strategy
=
'
not
'
):
distribution_strategy
=
None
):
"""
Creates a diagonal operator with the given power spectrum.
Constructs a diagonal operator that lives over the specified domain.
...
...
@@ -51,6 +52,10 @@ def create_power_operator(domain, power_spectrum, dtype=None,
"""
if
distribution_strategy
is
None
:
distribution_strategy
=
\
nifty_configuration
[
'
default_distribution_strategy
'
]
if
isinstance
(
power_spectrum
,
Field
):
power_domain
=
power_spectrum
.
domain
else
:
...
...
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