Skip to content

Commit

Permalink
Merge pull request #4 from Mulan-94/issue-3
Browse files Browse the repository at this point in the history
Issue 3
  • Loading branch information
Mulan-94 authored Dec 12, 2022
2 parents 4bff41d + 9beaabe commit 24e8a03
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
5 changes: 5 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
History
=======

0.1.5 (2022-12-7)
------------------
* Fixes error with ones rather than zero in the background


0.1.4 (2022-10-26)
------------------
* Fix naming of Stokes parameters
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
python-casacore
psutil
numpy
scabha
stimela @ git+https://github.com/caracal-pipeline/stimela2.git@master#egg=stimela
# include_package_data = False

# a key named with a single asterisk (*) below refers to all packages
Expand Down
2 changes: 1 addition & 1 deletion smops/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

__author__ = AUTHOR = """L Andati"""
__email__ = EMAIL = '[email protected]'
__version__ = VERSION = '0.1.4'
__version__ = VERSION = '0.1.5'
7 changes: 5 additions & 2 deletions smops/smooth.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,13 @@ def interp_cube(model, wsums, infreqs, outfreqs, ref_freq, spectral_poly_order):
result = {"xdims": nx, "ydims": ny}

# components excluding zeros
beta = np.ma.masked_equal(model.reshape(nband,-1), 0)
mask = np.any(model, axis=0)
beta = model*mask
beta = beta.reshape(nband, -1)


if spectral_poly_order > infreqs.size:
raise ValueError("spectral-poly-order can't be larger than nband")
raise ValueError(f"spectral-poly-order can't be larger than nband ({nband})")

# we are given frequencies at bin centers, convert to bin edges
#delta_freq is the same as CDELt value in the image header
Expand Down

0 comments on commit 24e8a03

Please sign in to comment.