Skip to content

Commit

Permalink
add wow correction to agc
Browse files Browse the repository at this point in the history
  • Loading branch information
happycube committed May 26, 2020
1 parent a607b4e commit 748048c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lddecode/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -2636,9 +2636,13 @@ def detectLevels(self, field):
for l in range(1,8):
lsa = field.lineslice(l, 10, 10)
lsb = field.lineslice(l, 40, 10)

# compute wow adjustment
thislinelen = field.linelocs[l + field.lineoffset] - field.linelocs[l + field.lineoffset - 1]
adj = field.rf.linelen / thislinelen

hlevels.append(np.mean(field.data['video']['demod_05'][lsa]))
hlevels.append(np.mean(field.data['video']['demod_05'][lsb]))
hlevels.append(np.mean(field.data['video']['demod_05'][lsa]) / adj)
hlevels.append(np.mean(field.data['video']['demod_05'][lsb]) / adj)

# Now group them by level (either sync or ire 0) and return the means of those
sync_hzs = []
Expand Down

0 comments on commit 748048c

Please sign in to comment.