__init__.py 4.83 KB
Newer Older
1
from .version import __version__
Martin Reinecke's avatar
Martin Reinecke committed
2

Martin Reinecke's avatar
Martin Reinecke committed
3
4
from . import random

Martin Reinecke's avatar
Martin Reinecke committed
5
6
7
8
9
10
11
12
13
14
from .domains.domain import Domain
from .domains.structured_domain import StructuredDomain
from .domains.unstructured_domain import UnstructuredDomain
from .domains.rg_space import RGSpace
from .domains.lm_space import LMSpace
from .domains.gl_space import GLSpace
from .domains.hp_space import HPSpace
from .domains.power_space import PowerSpace
from .domains.dof_space import DOFSpace

15
from .domain_tuple import DomainTuple
Martin Reinecke's avatar
Martin Reinecke committed
16
from .multi_domain import MultiDomain
17
from .field import Field
Martin Reinecke's avatar
Martin Reinecke committed
18
from .multi_field import MultiField
Philipp Arras's avatar
Fixups    
Philipp Arras committed
19

Philipp Arras's avatar
Philipp Arras committed
20

Martin Reinecke's avatar
Martin Reinecke committed
21
from .operators.operator import Operator
Philipp Arras's avatar
Philipp Arras committed
22
23
from .operators.linear_operator import LinearOperator

Philipp Arras's avatar
Philipp Arras committed
24
from .operators.adder import Adder
Martin Reinecke's avatar
Martin Reinecke committed
25
from .operators.diagonal_operator import DiagonalOperator
Martin Reinecke's avatar
cleanup    
Martin Reinecke committed
26
from .operators.distributors import DOFDistributor, PowerDistributor
Philipp Arras's avatar
Philipp Arras committed
27
from .operators.domain_tuple_field_inserter import DomainTupleFieldInserter
28
from .operators.einsum import LinearEinsum, MultiLinearEinsum
Philipp Arras's avatar
Philipp Arras committed
29
from .operators.contraction_operator import ContractionOperator, IntegrationOperator
30
from .operators.linear_interpolation import LinearInterpolator
Martin Reinecke's avatar
Martin Reinecke committed
31
from .operators.endomorphic_operator import EndomorphicOperator
Martin Reinecke's avatar
Martin Reinecke committed
32
33
34
from .operators.harmonic_operators import (
    FFTOperator, HartleyOperator, SHTOperator, HarmonicTransformOperator,
    HarmonicSmoothingOperator)
Martin Reinecke's avatar
Martin Reinecke committed
35
from .operators.field_zero_padder import FieldZeroPadder
Martin Reinecke's avatar
Martin Reinecke committed
36
37
from .operators.inversion_enabler import InversionEnabler
from .operators.mask_operator import MaskOperator
38
from .operators.regridding_operator import RegriddingOperator
39
from .operators.sampling_enabler import SamplingEnabler, SamplingDtypeSetter
Martin Reinecke's avatar
Martin Reinecke committed
40
41
from .operators.sandwich_operator import SandwichOperator
from .operators.scaling_operator import ScalingOperator
42
from .operators.selection_operators import SliceOperator, SplitOperator
Martin Reinecke's avatar
Martin Reinecke committed
43
from .operators.block_diagonal_operator import BlockDiagonalOperator
44
from .operators.outer_product_operator import OuterProduct
Martin Reinecke's avatar
Martin Reinecke committed
45
from .operators.simple_linear_operators import (
46
    VdotOperator, ConjugationOperator, Realizer, FieldAdapter, ducktape,
47
    GeometryRemover, NullOperator, PartialExtractor, Imaginizer)
48
from .operators.matrix_product_operator import MatrixProductOperator
Philipp Arras's avatar
Philipp Arras committed
49
from .operators.value_inserter import ValueInserter
Martin Reinecke's avatar
Martin Reinecke committed
50
from .operators.energy_operators import (
Martin Reinecke's avatar
merge    
Martin Reinecke committed
51
    EnergyOperator, GaussianEnergy, PoissonianEnergy, InverseGammaLikelihood,
52
    BernoulliEnergy, StandardHamiltonian, AveragedEnergy, QuadraticFormOperator,
53
    Squared2NormOperator, StudentTEnergy, VariableCovarianceGaussianEnergy)
54
from .operators.convolution_operators import FuncConvolutionOperator
55
from .operators.normal_operators import NormalTransform, LognormalTransform
Philipp Arras's avatar
Philipp Arras committed
56
57
from .operators.multifield2vector import Multifield2Vector

Martin Reinecke's avatar
Martin Reinecke committed
58
from .probing import probe_with_posterior_samples, probe_diagonal, \
59
    StatCalculator, approximation2endo
Martin Reinecke's avatar
Martin Reinecke committed
60
61

from .minimization.line_search import LineSearch
Martin Reinecke's avatar
Martin Reinecke committed
62
from .minimization.iteration_controllers import (
Martin Reinecke's avatar
Martin Reinecke committed
63
    IterationController, GradientNormController, DeltaEnergyController,
64
    GradInfNormController, AbsDeltaEnergyController)
Martin Reinecke's avatar
Martin Reinecke committed
65
66
67
from .minimization.minimizer import Minimizer
from .minimization.conjugate_gradient import ConjugateGradient
from .minimization.nonlinear_cg import NonlinearCG
68
from .minimization.descent_minimizers import (
69
70
    DescentMinimizer, SteepestDescent, VL_BFGS, L_BFGS, RelaxedNewton,
    NewtonCG)
71
from .minimization.stochastic_minimizer import ADVIOptimizer
Martin Reinecke's avatar
Martin Reinecke committed
72
from .minimization.scipy_minimizer import L_BFGS_B
Martin Reinecke's avatar
Martin Reinecke committed
73
74
from .minimization.energy import Energy
from .minimization.quadratic_energy import QuadraticEnergy
Martin Reinecke's avatar
Martin Reinecke committed
75
from .minimization.energy_adapter import EnergyAdapter
Philipp Frank's avatar
Philipp Frank committed
76
from .minimization.kl_energies import MetricGaussianKL, GeoMetricKL
Martin Reinecke's avatar
Martin Reinecke committed
77

Martin Reinecke's avatar
Martin Reinecke committed
78
from .sugar import *
Philipp Arras's avatar
Fixes    
Philipp Arras committed
79

80
from .plot import Plot
Philipp Arras's avatar
Fixups    
Philipp Arras committed
81

Philipp Arras's avatar
Philipp Arras committed
82
83
from .library.special_distributions import InverseGammaOperator, \
    UniformOperator, LaplaceOperator, LogInverseGammaOperator
Martin Reinecke's avatar
Martin Reinecke committed
84
from .library.los_response import LOSResponse
Philipp Arras's avatar
Philipp Arras committed
85
86
from .library.dynamic_operator import (dynamic_operator,
                                       dynamic_lightcone_operator)
87
from .library.light_cone_operator import LightConeOperator
Martin Reinecke's avatar
merge    
Martin Reinecke committed
88

Philipp Arras's avatar
Fixup    
Philipp Arras committed
89
from .library.wiener_filter_curvature import WienerFilterCurvature
90
from .library.adjust_variances import (make_adjust_variances_hamiltonian,
Martin Reinecke's avatar
Martin Reinecke committed
91
                                       do_adjust_variances)
Philipp Arras's avatar
Philipp Arras committed
92
from .library.nft import Gridder, FinuFFT
Philipp Arras's avatar
Philipp Arras committed
93
from .library.correlated_fields import CorrelatedFieldMaker
Philipp Arras's avatar
Philipp Arras committed
94
from .library.correlated_fields_simple import SimpleCorrelatedField
Philipp Frank's avatar
Philipp Frank committed
95
from .library.variational_models import MeanField, FullCovariance
Martin Reinecke's avatar
Martin Reinecke committed
96

Philipp Arras's avatar
Move it    
Philipp Arras committed
97
from . import extra
98

99
from .utilities import memo, frozendict, myassert
Martin Reinecke's avatar
Martin Reinecke committed
100

Martin Reinecke's avatar
Martin Reinecke committed
101
102
from .logger import logger

Philipp Arras's avatar
Fixes    
Philipp Arras committed
103
104
from .linearization import Linearization

105
106
from .operator_spectrum import operator_spectrum

Rouven Lemmerz's avatar
Rouven Lemmerz committed
107
108
from .operator_tree_optimiser import optimise_operator

109
# We deliberately don't set __all__ here, because we don't want people to do a
Martin Reinecke's avatar
Martin Reinecke committed
110
# "from nifty7 import *"; that would swamp the global namespace.