Ejemplo n.º 1
0
def test_conv_hg_hcc():
    coord = [34.0, 96.0]
    result = wcs.convert_hg_hcc(img.rsun_meters, img.heliographic_latitude, 
                                img.heliographic_longitude, coord[0], coord[1])
    known_answer = [-40653538.0, 6.7903529e08]
    magnitude = np.floor(np.log10(np.abs(known_answer)))
    assert_array_almost_equal(result*10**(-magnitude), 
                              known_answer*10**(-magnitude), decimal=2)
Ejemplo n.º 2
0
def test_conv_hg_hcc():
    coord = [34.0, 96.0]
    result = wcs.convert_hg_hcc(img.rsun_meters, img.heliographic_latitude,
                                img.heliographic_longitude, coord[0], coord[1])
    known_answer = [-40653538.0, 6.7903529e08]
    magnitude = np.floor(np.log10(np.abs(known_answer)))
    assert_array_almost_equal(result * 10**(-magnitude),
                              known_answer * 10**(-magnitude),
                              decimal=2)
Ejemplo n.º 3
0
def test_conv_hg_hcc():
    coord = [34.0, 96.0]
    result = wcs.convert_hg_hcc(img.rsun_arcseconds, img.get_solar_b0(), 
                                img.heliographic_longitude, coord[0], coord[1])
    assert_array_almost_equal(result, [-40653538.0, 6.7903529e08], decimal=2)
Ejemplo n.º 4
0
def test_conv_hg_hcc():
    coord = [34.0, 96.0]
    result = wcs.convert_hg_hcc(header, coord[0], coord[1])
    assert_array_almost_equal(result, [-40653538.0, 6.7903529e08], decimal=2)