Esempio n. 1
0
def _MIL2ASAE_fname(date, path, orbit):

    orbit = fN.orbit2str(orbit)
    path = fN.path2str(path)

    from constant import HEADER_MIL2ASAE_FILENAME
    dir_aerosol = header_file_aerosol + date
    file_aerosol = dir_aerosol + '/' + HEADER_MIL2ASAE_FILENAME + path + '_O' + orbit + '_F12_0022.hdf'

    return str(file_aerosol)
Esempio n. 2
0
def mil2asae(date, path, orbit):

    from constant import HEADER_MIL2ASAE_FILENAME, HEADER_MIL2ASAE_URL

    orbit = fN.orbit2str(orbit)
    path = fN.path2str(path)

    dir_aerosol = '../../projects/aerosol/products/MIL2ASAE/' + date

    if not os.path.exists(dir_aerosol):
        os.makedirs(dir_aerosol)

    file_name = HEADER_MIL2ASAE_FILENAME + path + '_O' + orbit + '_F12_0022.hdf'
    local_file_name = dir_aerosol + '/' + file_name
    file_url = HEADER_MIL2ASAE_URL + date + '/' + file_name

    _fetch(file_url, local_file_name)
Esempio n. 3
0
def mi1b2t(date, path, orbit, cam):

    from constant import HEADER_MI1B2T_FILENAME
    from constant import HEADER_MI1B2T_URL

    orbit = fN.orbit2str(orbit)
    path = fN.path2str(path)

    dir_radiance = '../../projects/aerosol/products/MI1B2T/' + date
    if not os.path.exists(dir_radiance):
        os.makedirs(dir_radiance)

    file_name = HEADER_MI1B2T_FILENAME + path + '_O' + orbit + '_' + cam + '_F03_0024.hdf'
    local_file_name = dir_radiance + '/' + file_name
    file_url = HEADER_MI1B2T_URL + date + '/' + file_name

    _fetch(file_url, local_file_name)
Esempio n. 4
0
def miancagp(path):

    from constant import HEADER_MIANCAGP_FILENAME, HEADER_MIANCAGP_URL1, HEADER_MIANCAGP_URL2

    path = fN.path2str(path)

    dir_geo = 'product/MIANCAGP'

    if not os.path.exists(dir_geo):
        os.makedirs(dir_geo)

    file_name = HEADER_MIANCAGP_FILENAME + path + '_F01_24.hdf'
    local_file_name = dir_geo + '/' + file_name
    file_url = [HEADER_MIANCAGP_URL1+file_name,HEADER_MIANCAGP_URL2+file_name]

    for i in [0, 1]:
        try:
            _fetch(file_url[i], local_file_name)
            break

        except IOError:
            print "file doesn't exist at {}".format(file_url[i])
Esempio n. 5
0
def _result_fname(date, path, orbit, block, r, Method):

    orbit = fN.orbit2str(orbit)
    path = fN.path2str(path)

    return str(header_result + date + '_P' + path + '_O' + orbit + '_B' + str(block) + '_R' + str(r) + '_' + Method + '.mat')
Esempio n. 6
0
def _reg_mat_fname(date, path, orbit, block, r):

    orbit = fN.orbit2str(orbit)
    path = fN.path2str(path)

    return str(header_data + date + '_P' + path + '_O' + orbit + '_B' + str(block) + '_R' + str(r) + '.mat')