Skip to content

Commit

Permalink
add DB fields for polarization standards
Browse files Browse the repository at this point in the history
  • Loading branch information
juanep97 committed Dec 22, 2024
1 parent ae9fc63 commit e11ce18
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion iop4lib/db/astrosource.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,12 @@ class AstroSource(models.Model):

calibrates = models.ManyToManyField('AstroSource', related_name="calibrators", blank=True, help_text="sources that it calibrates (for calibrators only)")

p = models.FloatField(blank=True, null=True, help_text="Polarization degree [0-1] (for calibrators only)")
p_err = models.FloatField(blank=True, null=True, help_text="Polarization degree error (for calibrators only)")

chi = models.FloatField(blank=True, null=True, help_text="Polarization angle [deg] (for calibrators only)")
chi_err = models.FloatField(blank=True, null=True, help_text="Polarization angle error (for calibrators only)")

mag_R = models.FloatField(blank=True, null=True, help_text="Literature magnitude in R band (for calibrators only)")
mag_R_err = models.FloatField(blank=True, null=True, help_text="Literature magnitude error in R band (for calibrators only)")

Expand Down Expand Up @@ -199,7 +205,7 @@ def get_sources_in_field(cls, wcs=None, width=None, height=None, fit=None, qs=No
sources_in_field = list()

import warnings
for obj in qs:
for obj in qs.iterator():
try:
with warnings.catch_warnings():
warnings.simplefilter("ignore")
Expand Down

0 comments on commit e11ce18

Please sign in to comment.