当前位置: 首页>>代码示例>>Python>>正文


Python Vizier.find_catalogs方法代码示例

本文整理汇总了Python中astroquery.vizier.Vizier.find_catalogs方法的典型用法代码示例。如果您正苦于以下问题:Python Vizier.find_catalogs方法的具体用法?Python Vizier.find_catalogs怎么用?Python Vizier.find_catalogs使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在astroquery.vizier.Vizier的用法示例。


在下文中一共展示了Vizier.find_catalogs方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: search_catalog

# 需要导入模块: from astroquery.vizier import Vizier [as 别名]
# 或者: from astroquery.vizier.Vizier import find_catalogs [as 别名]
    def search_catalog(self, term, obsolete):

        json_result = '{"catalogs":[]}'

        try:
            catalog_list = Vizier.find_catalogs(term, include_obsolete=obsolete)

            if catalog_list:
                catalogs = CatalogCollection(catalog_list)
                json_result = dumper(catalogs)
                self.logger.info("Result from Vizier catalog search for '{0}' \n {1}".format(term, json_result))
            else:
                self.logger.info("Nothing found for '{0}'".format(term))
        except:
            self.logger.error("Error in SimbadProvider", exc_info=True)
            raise ProviderException("error", "something")

        return json_result
开发者ID:Civa,项目名称:Zenith,代码行数:20,代码来源:vizier.py

示例2: get_usnob1_cat

# 需要导入模块: from astroquery.vizier import Vizier [as 别名]
# 或者: from astroquery.vizier.Vizier import find_catalogs [as 别名]
import numpy as np
from astroquery.vizier import Vizier
from astropy.coordinates import SkyCoord
import astropy.units as u
from astropy import table
import numpy as np

usnob_cat = Vizier.find_catalogs('USNO-B1.0')

def get_usnob1_cat(ra, dec, blim):
    ra_u = ra*u.degree
    dec_u = dec*u.degree
    coords = SkyCoord(ra_u, dec_u, frame='icrs') #Should this be ICRS or FK5
    #Only Class 0 (stars) - unable to implement this at the current time. Need to understand
    #USNO-B1 s/g classification
    v = Vizier(columns=['USNO-B1.0', '_RAJ2000', '_DEJ2000', 
                        'B1mag', 'R1mag', 'B2mag', 'R2mag', 
                        'pmRA', 'pmDE', 'Imag', 'B1s/g', '_r'],
                row_limit=500000,
               column_filters={"B2mag":">6", 'B2mag':'<{}'.format(blim)}) #B2mag fainter than 6, brighter than blim
    new_table_list = v.query_region(coords, 
                                 radius=900*u.arcsecond, #Search 900 arcseconds
                                 catalog = 'I/284')
    if len(new_table_list) ==0:
        return None
    else:
        new_table = new_table_list[0]
    #Get the 5000 closest
    new_table.sort('_r')
    if len(new_table) > 5000:
        new_table.remove_rows(np.arange(5001, len(new_table)))
开发者ID:PaulKuin,项目名称:uvotpy,代码行数:33,代码来源:generate_USNOB1_cat.py

示例3: len

# 需要导入模块: from astroquery.vizier import Vizier [as 别名]
# 或者: from astroquery.vizier.Vizier import find_catalogs [as 别名]
from astroquery.vizier import Vizier
catalog_list = Vizier.find_catalogs('J/ApJS/204/5')
Vizier.ROW_LIMIT = -1

cata = Vizier.get_catalogs(catalog_list.keys())[0]
print len(cata)
开发者ID:StuartLittlefair,项目名称:PHY241,代码行数:8,代码来源:sdss_wds.py

示例4: Vizier

# 需要导入模块: from astroquery.vizier import Vizier [as 别名]
# 或者: from astroquery.vizier.Vizier import find_catalogs [as 别名]
    # the luminosity is just not right...
    # (this is not included in the paper because I'm worried about a factor of
    # at least 4 pi being left out...)
    sfr2cm = ((cont2cm*u.K).to(u.Jy, u.brightness_temperature(gbbeamarea,
                                                              h2co22freq)) *
              #gb_ppbeam / gb_pixelsize_deg**2 * u.sr *
              #(4*np.pi*distance**2) *
              distance**2 *  # there is a 4 pi missing here... but it may come from elsewhere
              sfrperergshz).to(u.M_sun/u.yr)
    sfr2cmd = (sfr2cm / pixel_area).to(u.M_sun/u.yr/u.kpc**2)
    ok2cm = cont2cm > 0.1



    from astroquery.vizier import Vizier
    catalog_list = Vizier.find_catalogs('Kang W51')
    ysos = Vizier(row_limit=1e6).query_region(coordinates.SkyCoord.from_name('W51'),
                                              radius=1*u.deg,
                                              catalog=catalog_list.keys())
    cl1lt10 = ((ysos[0]['Cl1'] == 'I') |
               (ysos[0]['Cl1'] == 'F') |
               (ysos[0]['Cl2'] == 'I') |
               (ysos[0]['Cl2'] == 'F')) & (ysos[0]['Mstar'] < 10)
    cl1gt10 = ((ysos[0]['Cl1'] == 'I') |
               (ysos[0]['Cl1'] == 'F') |
               (ysos[0]['Cl2'] == 'I') |
               (ysos[0]['Cl2'] == 'F')) & (ysos[0]['Mstar'] >= 10)
    cl1lt10coords = coordinates.SkyCoord(ysos[0][cl1lt10]['_RAJ2000'],
                                         ysos[0][cl1lt10]['_DEJ2000'],
                                         frame='fk5').galactic
    cl1gt10coords = coordinates.SkyCoord(ysos[0][cl1gt10]['_RAJ2000'],
开发者ID:keflavich,项目名称:w51_singledish_h2co_maps,代码行数:33,代码来源:co_intmaps.py

示例5:

# 需要导入模块: from astroquery.vizier import Vizier [as 别名]
# 或者: from astroquery.vizier.Vizier import find_catalogs [as 别名]
import matplotlib.pyplot as plt
import matplotlib.lines as mlines
from matplotlib.patches import Circle
import mpl_toolkits.mplot3d.art3d as art3d
from astroquery.vizier import Vizier

from spaceutils import show_maximized_plot, kiloparsec_to_lightyear


# =====================================================================================================


catalog_list = Vizier.find_catalogs('VII/202')
Vizier.ROW_LIMIT = 1000000
catalogs = Vizier.get_catalogs(catalog_list.keys())
data = catalogs[0]


# =====================================================================================================

data.sort('Name')

data["X"] = kiloparsec_to_lightyear(data["X"])
data["Y"] = kiloparsec_to_lightyear(data["Y"])
data["Z"] = kiloparsec_to_lightyear(data["Z"])
data["Rsun"] = kiloparsec_to_lightyear(data["Rsun"])

SUN_TO_CENTER_DISTANCE = 27200
MILKY_WAY_RADIUS = 110000 / 2

开发者ID:vovaprog,项目名称:python_space,代码行数:31,代码来源:globular_clusters_astroquery.py


注:本文中的astroquery.vizier.Vizier.find_catalogs方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。