Skip to content

Commit

Permalink
remove warning for pol_convention in uvdata and uvcal
Browse files Browse the repository at this point in the history
  • Loading branch information
steven-murray committed Jul 11, 2024
1 parent 985731d commit 22713d7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 14 deletions.
7 changes: 0 additions & 7 deletions src/pyuvdata/uvcal/uvcal.py
Original file line number Diff line number Diff line change
Expand Up @@ -1653,13 +1653,6 @@ def check(
check_extra=check_extra, run_check_acceptability=run_check_acceptability
)

# Check consistency between pol_convention and units of data
if self.pol_convention is None:
warnings.warn(
"pol_convention is unset. This leaves the "
"convention ambiguous. Consider setting pol_convention to 'sum' or 'avg'."
)

# then run telescope object check
self.telescope.check(
check_extra=check_extra, run_check_acceptability=run_check_acceptability
Expand Down
8 changes: 1 addition & 7 deletions src/pyuvdata/uvdata/uvdata.py
Original file line number Diff line number Diff line change
Expand Up @@ -2215,13 +2215,7 @@ def check(
logger.debug("... Done UVBase Check")

# Check consistency between pol_convention and units of data
if self.vis_units != "uncalib" and self.pol_convention is None:
warnings.warn(
"pol_convention is unset and the data is calibrated. This leaves the "
"convention ambiguous. Consider setting pol_convention to 'sum' or "
"'avg'."
)
elif self.vis_units == "uncalib" and self.pol_convention is not None:
if self.vis_units == "uncalib" and self.pol_convention is not None:
raise ValueError(
"pol_convention is set but the data is uncalibrated. This "
"is not allowed."
Expand Down

0 comments on commit 22713d7

Please sign in to comment.