Repository: lgrcia/prose

Issue:
Image header is ignored
I think the `header` keyword to `Image` instance is being ignored because of [this line](https://github.com/lgrcia/prose/blob/eedfa9f19773333f344206f2bceec2ced398c279/prose/core/image.py#L75).

```python
import prose
print(prose.__version__)
from prose import Image
import numpy as np

d = np.ones((512,512))
hdr = dict(FILTER='B')

print(Image(d, header=hdr).header)
# hack to get around the bug
print(Image(d, computed=(dict(fits_header=hdr))).header)
```

output:
3.3.1
END                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             
{'FILTER': 'B'}

Hints from issue comments:
@lgrcia: Thanks for opening this issue @smoh! I opened and merged a pull request to fix it. It is now part of the patched version `3.3.2`, published on pypi.@smoh: Thank you! I will check it out.

Solution patch:
diff --git a/prose/core/image.py b/prose/core/image.py
index edd14bc..bf01d9c 100644
--- a/prose/core/image.py
+++ b/prose/core/image.py
@@ -71,11 +71,10 @@ class Image:
         if self.computed is None:
             self.computed = {}
 
-        # backward compatibility
-        self.header = self.computed.get("fits_header", None)
-
         if self.header is None:
-            self.header = Header()
+            # backward compatibility
+            self.header = self.computed.get("fits_header", Header())
+
         if isinstance(self._sources, dict):
             self._sources = Sources(**self._sources)
         if self._sources is None:
diff --git a/pyproject.toml b/pyproject.toml
index 3132505..7392b24 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
 [tool.poetry]
 name = "prose"
-version = "3.3.1"
+version = "3.3.2"
 description = "Modular image processing pipelines for Astronomy"
 authors = ["Lionel Garcia"]
 license = "MIT"


Test patch:
diff --git a/tests/test_image.py b/tests/test_image.py
index 456553c..7a5ffee 100644
--- a/tests/test_image.py
+++ b/tests/test_image.py
@@ -54,3 +54,11 @@ def test_fitsimage(tmp_path):
 
     loaded_image = FITSImage(filename)
     assert "IMAGETYP" in dict(loaded_image.header)
+
+
+def test_init_header():
+
+    d = np.ones((512, 512))
+    hdr = dict(FILTER="B")
+
+    assert Image(d, header=hdr).header == hdr