GBMClient

class sunpy.net.dataretriever.GBMClient[source]

Bases: sunpy.net.dataretriever.client.GenericClient

Provides access to data from the Gamma-Ray Burst Monitor (GBM) instrument on board the Fermi satellite.

Although GBMs primary objective is to detect gamma-ray bursts, it provides high quality high energy solar flare observations.

The instrument consists of 12 Sodium Iodide (NaI) scintillation detectors, which are sensitive to an energy range of 4keV to 1MeV. At any one time, 6 of the NaI detectors are Sunward facing. The detectors are numbered ‘n1’ to ‘n11’. This client supports the user to choose which detector to use through the a.Detector attribute. The default detector is ‘n5’.

The GBM data comes in daily version files in two formats:

  • CSPEC - counts accumulated every 4.096 seconds in 128 energy channels for each detector.

  • CTIME - counts accumulated every 0.256 seconds in 8 energy channels

Both of which can be accessed through the attrs a.Resolution. The default data type is CSPEC unless the user defines.

Examples

>>> from sunpy.net import Fido, attrs as a
>>> res = Fido.search(a.Time('2015-06-21 00:00', '2015-06-23 23:59'),
...                   a.Instrument.gbm, a.Detector.n3,
...                   a.Resolution.ctime) 
>>> res 
<sunpy.net.fido_factory.UnifiedResponse object at ...>
Results from 1 Provider:

3 Results from the GBMClient:
       Start Time               End Time        ... Resolution Detector
----------------------- ----------------------- ... ---------- --------
2015-06-21 00:00:00.000 2015-06-21 23:59:59.999 ...      ctime       n3
2015-06-22 00:00:00.000 2015-06-22 23:59:59.999 ...      ctime       n3
2015-06-23 00:00:00.000 2015-06-23 23:59:59.999 ...      ctime       n3

Attributes Summary

baseurl

A regex string that can match all urls supported by the client.

pattern

A string which is used to extract the desired metadata from urls correctly, using sunpy.extern.parse.parse.

Methods Summary

register_values()

This enables the client to register what kind of Attrs it can use directly.

Attributes Documentation

baseurl = 'https://heasarc.gsfc.nasa.gov/FTP/fermi/data/gbm/daily/%Y/%m/%d/current/glg_(\\w){5}_(\\w){2}_%y%m%d_v00.pha'

A regex string that can match all urls supported by the client.

pattern = '{}/daily/{year:4d}/{month:2d}/{day:2d}/current/glg_{Resolution:5}_{Detector:2}_{:6d}{}'

A string which is used to extract the desired metadata from urls correctly, using sunpy.extern.parse.parse.

Methods Documentation

classmethod register_values()[source]

This enables the client to register what kind of Attrs it can use directly.

Returns

dict – A dictionary with key values of Attrs and the values are a tuple of (“Attr Type”, “Name”, “Description”).