示例#1
0
    p1 = astmodels.Polynomial1D(1)
    p2 = astmodels.Polynomial1D(1)
    p3 = astmodels.Polynomial1D(1)
    p4 = astmodels.Polynomial1D(1)
    m1 = p1 & p2
    m2 = p3 & p4
    m1.inverse = m2
    return m1


test_models = [
    astmodels.Identity(2),
    astmodels.Polynomial1D(2, c0=1, c1=2, c2=3),
    astmodels.Polynomial2D(1, c0_0=1, c0_1=2, c1_0=3),
    astmodels.Shift(2.),
    astmodels.Hermite1D(2, c0=2, c1=3, c2=0.5),
    astmodels.Legendre1D(2, c0=2, c1=3, c2=0.5),
    astmodels.Chebyshev1D(2, c0=2, c1=3, c2=0.5),
    astmodels.Chebyshev2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astmodels.Legendre2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astmodels.Hermite2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astmodels.Scale(3.4),
    astmodels.RotateNative2Celestial(5.63, -72.5, 180),
    astmodels.Multiply(3),
    astmodels.Multiply(10 * u.m),
    astmodels.RotateCelestial2Native(5.63, -72.5, 180),
    astmodels.EulerAngleRotation(23, 14, 2.3, axes_order='xzx'),
    astmodels.Mapping((0, 1), n_inputs=3),
    astmodels.Shift(2. * u.deg),
    astmodels.Scale(3.4 * u.deg),
    astmodels.RotateNative2Celestial(5.63 * u.deg, -72.5 * u.deg, 180 * u.deg),
示例#2
0
                               c0=2,
                               c1=3,
                               c2=0.5,
                               domain=(0.0, 1.0),
                               window=(1.5, 2.5)),
    astropy_models.Chebyshev2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astropy_models.Chebyshev2D(1,
                               1,
                               c0_0=1,
                               c0_1=2,
                               c1_0=3,
                               x_domain=(1.0, 2.0),
                               y_domain=(3.0, 4.0),
                               x_window=(5.0, 6.0),
                               y_window=(7.0, 8.0)),
    astropy_models.Hermite1D(2, c0=2, c1=3, c2=0.5),
    astropy_models.Hermite2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astropy_models.Legendre1D(2, c0=2, c1=3, c2=0.5),
    astropy_models.Legendre2D(1, 1, c0_0=1, c0_1=2, c1_0=3),
    astropy_models.Polynomial1D(2, c0=1, c1=2, c2=3),
    astropy_models.Polynomial2D(1, c0_0=1, c0_1=2, c1_0=3),

    # astropy.modeling.powerlaws
    astropy_models.BrokenPowerLaw1D(amplitude=10,
                                    x_break=0.5,
                                    alpha_1=2.0,
                                    alpha_2=3.5),
    astropy_models.ExponentialCutoffPowerLaw1D(10, 0.5, 2.0, 7.),
    astropy_models.LogParabola1D(
        amplitude=10,
        x_0=0.5,