How to query VSO for XRT data using the various metadata available

Hi,

I am now able to query the VSO and get Hinode XRT data based on their observation times. I was told by Alisdair Davey that a range of other metadata is currently stored for the data files as well (he provided a list) including, e.g. ec_fw1_ (Filter wheel 1). It’s unclear to me though how to query using the fields that are stored. For time I can do:
res = Fido.search(a.Time("2012-06-05 21:58:39", "2012-06-05 21:59:00"), a.Instrument("xrt"))
for example. That uses the Time class of sunpy.net.attrs. But how to search on, filter wheel for example is unclear to me. I’ve tried a few things but so far nothing has worked. Any help would be appreciated.

Thanks,
Jon

1 Like

Hi @jdslavin , thanks for posting your question here!

So at the moment, it looks like that information is in the wavelength attribute, however this is not what you are looking for (i.e. figuring out the wavelength range from the filter wheel you are interested in etc). Although I could be wrong, it does not look like that metadata is accessible at the moment. We’re asking the VSO folks now as currently it looks like its not there as a way to query.

2 Likes

I tried using the VSO website and Fido with debug:

In [1]: from sunpy.net import attrs as a, Fido

In [2]: from sunpy import log

In [3]: log.info
Out[3]: <bound method Logger.info of <SunpyLogger sunpy (INFO)>>

In [4]: log.setLevel("DEBUG")

In [5]: Fido.search(a.Time("2012-06-05 21:58:39", "2012-06-05 21:59:00"), a.Instrument("xrt"))
DEBUG: VSO Request:
 <soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:VSO="http://virtualsolar.org/VSO/VSOi">
  <soap-env:Body>
    <VSO:Query>
      <body>
        <block>
          <time>
            <start>20120605215839</start>
            <end>20120605215900</end>
          </time>
          <instrument>xrt</instrument>
        </block>
      </body>
    </VSO:Query>
  </soap-env:Body>
</soap-env:Envelope>
 [sunpy.net.vso.zeep_plugins]
DEBUG: VSO Response:
 <soap:Envelope xmlns:VSO="http://virtualsolar.org/VSO/VSOi" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <soap:Body>
    <VSO:QueryResponse>
      <body>
        <provideritem>
          <record>
            <recorditem>
              <instrument>XRT</instrument>
              <source>Hinode</source>
              <physobs>Intensity</physobs>
              <info/>
              <fileid>https://umbra.nascom.nasa.gov/hinode/xrt/level1/2012/06/05/H2100/L1_XRT20120605_215839.9.fits</fileid>
              <time>
                <start>2012-06-05 21:58:39.912</start>
                <end>2012-06-05 21:58:48.103</end>
              </time>
              <extent>
                <x>-746.001282</x>
                <type>PARTIAL_SUN</type>
                <y>558.335022</y>
              </extent>
              <provider>SAO</provider>
              <wave>
                <wavemax>200</wavemax>
                <wavemin>3</wavemin>
                <wavetype>Broad</wavetype>
                <waveunit>Angstrom</waveunit>
              </wave>
              <size>607680</size>
            </recorditem>
          </record>
          <no_of_records_returned>1</no_of_records_returned>
          <provider>SAO</provider>
          <no_of_records_found>1</no_of_records_found>
          <version>1</version>
        </provideritem>
      </body>
    </VSO:QueryResponse>
  </soap:Body>
</soap:Envelope>
 [sunpy.net.vso.zeep_plugins]
Out[5]:
<sunpy.net.fido_factory.UnifiedResponse object at 0x7fab588ab6d0>
Results from 1 Provider:

1 Results from the VSOClient:
Source: http://vso.stanford.edu/cgi-bin/search
Total estimated size: 622.264 Mbyte

       Start Time               End Time        Source Instrument  Wavelength  Provider  Physobs  Wavetype   Extent X   Extent Y  Extent Type   Size
                                                                    Angstrom                                                                   Mibyte
----------------------- ----------------------- ------ ---------- ------------ -------- --------- -------- ----------- ---------- ----------- --------
2012-06-05 21:58:39.912 2012-06-05 21:58:48.103 Hinode        XRT 3.0 .. 200.0      SAO Intensity    Broad -746.001282 558.335022 PARTIAL_SUN 593.4375

I do not see any return from the VSO with the filter wheel name. We will need to ask the VSO folks about this as I do not see any way to search using that metadata information.

1 Like