Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add local support for EUI
Browse files Browse the repository at this point in the history
bogdanni committed Jun 23, 2021
1 parent 4080fd2 commit a3d9b9d
Showing 2 changed files with 16 additions and 0 deletions.
2 changes: 2 additions & 0 deletions install/helioviewer/jp2parser.py
Original file line number Diff line number Diff line change
@@ -14,6 +14,8 @@
from glymur import Jp2k
from sunpy.util.xml import xml_to_dict

from sources.EUI import EUIMap

__HV_CONSTANT_RSUN__ = 959.644
__HV_CONSTANT_AU__ = 149597870700

14 changes: 14 additions & 0 deletions install/sources/EUI.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

from sunpy.map import GenericMap

class EUIMap(GenericMap):

def __init__(self, data, header, **kwargs):
GenericMap.__init__(self, data, header, **kwargs)

self.meta["detector"] = header.get("detector").split("_")[0]
self.meta["obsrvtry"] = "SOLO"

@classmethod
def is_datasource_for(cls, data, header, **kwargs):
return header.get("instrume") == "EUI"

0 comments on commit a3d9b9d

Please sign in to comment.