我需要在此特定目录中搜索此坐标附近的对象。我正在尝试对其进行编码,因为我不仅有这个对象,而且还有很多其他对象。
设置它:
>>> from astropy.vo.client import conesearch
>>> from astropy.coordinates import SkyCoord
>>> from astropy import units as u
>>> db = 'SDSS DR8 - Sloan Digital Sky Survey Data Release 8 2'
>>> search_size = 1*u.deg
>>> c = SkyCoord(ra = 305.008942, dec = -0.975747, unit=u.deg)
运行它:
>>> conesearch.conesearch(c, search_size, catalog_db=db)
Trying http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&
Downloading http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpeDownloading http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1 [Done]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:51:0: W50: Invalid unit string 'days' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:237:0: W50: Invalid unit string 'Angstroms' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:240:0: W50: Invalid unit string 'Angstroms' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:345:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:348:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:351:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:354:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:357:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:360:0: W50: Invalid unit string 'nanomaggies' [astropy.io.votable.exceptions]
WARNING: W50: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:363:0: W50: Invalid unit string 'nanomaggies' (suppressing further warnings of this type...) [astropy.io.votable.exceptions]
WARNING: W06: http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&SR=1.0&DEC=-0.975747&RA=305.008942&VERB=1:462:0: W06: Invalid UCD 'IMAGE?': UCD has invalid character '?' in 'IMAGE?' [astropy.io.votable.exceptions]
WARNING: W25: ?:?:?: W25: 'http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&' failed with: Catalog server 'http://wfaudata.roe.ac.uk/sdssdr8-dsa/DirectCone?DSACAT=SDSS_DR8&DSATAB=SpecObjAll&' returned 0 result [astropy.io.votable.exceptions]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.7/site-packages/astropy/vo/client/conesearch.py", line 191, in conesearch
kwargs=args, **kwargs)
File "/usr/local/lib/python2.7/site-packages/astropy/vo/client/vos_catalog.py", line 877, in call_vo_service
raise VOSError(err_msg)
astropy.vo.client.exceptions.VOSError: None of the available catalogs returned valid results.
我知道警告只是 SDSS 设置搜索方式的奇怪问题,它不应该影响任何事情。我已经尝试了高达 20 度,但仍然找不到任何东西。这是错误的,因为我还有其他 20 度角的物体,它们会找到物体!