Browse Source

Updated python to use (through env)

master
Jops 2 years ago
parent
commit
81031bf8d6
8 changed files with 10 additions and 10 deletions
  1. +1
    -1
      antabfs_interpolate.py
  2. +1
    -1
      antabfs_nominal.py
  3. +1
    -1
      expname.py
  4. +3
    -3
      flag_weights.py
  5. +1
    -1
      multiphase_sfxc2ms.py
  6. +1
    -1
      polswap.py
  7. +1
    -1
      split_vexfile.py
  8. +1
    -1
      ysfocus.py

+ 1
- 1
antabfs_interpolate.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
description = """
Given an ANTAB file, it creates a new one with more Tsys values that are interpolated from the
given ones. This will fill gaps when the time separation between Tsys measurements is too long


+ 1
- 1
antabfs_nominal.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
"""
Python port of Bob Campbell's IDL script to make nominal tsys tables.
It takes the nominal SEFD values from the sefd_values.txt table and generates an ANTAB file using


+ 1
- 1
expname.py View File

@@ -1,4 +1,4 @@
#! /usr/bin/python
#! /usr/bin/env python3
"""Change the name of an project in a measurement set (MS).

Usage: expname.py <msdata> <new_expname>


+ 3
- 3
flag_weights.py View File

@@ -1,4 +1,4 @@
#! /usr/bin/python
#!/usr/bin/env python3
"""
Flag visibilities with weights below the provided threshold.

@@ -75,14 +75,14 @@ with pt.table(msdata, readonly=False, ack=False) as ms:
indexes = np.where(weights < threshold)
indexes2 = np.where((weights < threshold) & (weights > 0.0))
print('Got {0:9} bad points'.format(indexes[0].size))
print('{0:04.3}% of the total visibilities to flag\n'.format(100.0*indexes[0].size/weights.size))
print('{0:04.3}% of the total visibilities to flag'.format(100.0*indexes[0].size/weights.size))
print('{0:04.3}% of actual data (non-zero) to flag\n'.format(100.0*indexes2[0].size/weights.size))
if verbose:
weights[indexes] = -np.abs(weights[indexes])
ms.putcol("WEIGHT", weights)
print('Done.')
else:
rint('Flag has not been applied.')
print('Flag has not been applied.')

ms.close()



+ 1
- 1
multiphase_sfxc2ms.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
"""Takes the default {exp}_sfxc2ms.sh file produced by the sfxc2ms.pl script and adds the _SRCname to the .cor files.

Generates different {exp}_sfxc2ms_SRCname.sh files for the different phase centers (detailed in SRCname).


+ 1
- 1
polswap.py View File

@@ -1,4 +1,4 @@
#! /usr/bin/python3
#! /usr/bin/env python3
"""
Swap polarizations for specified antennas and for a specific timerange.



+ 1
- 1
split_vexfile.py View File

@@ -1,4 +1,4 @@
#! /usr/bin/python3
#!/usr/bin/env python3
"""
Given a VEX file, it creates a new VEX file that is a subset of the given one,
dropping all the information (stations, source, PI names) that are not included


+ 1
- 1
ysfocus.py View File

@@ -1,4 +1,4 @@
#! /usr/bin/python
#!/usr/bin/env python3
"""
Change the MOUNT field in the ANTENNA table for Ys to 'ALT-AZ-NASMYTH-RH'.
It allows tConvert to put MNTSTA=4 into the FITS AN table, to handle the


Loading…
Cancel
Save