Package: pythonSCHED
pySCHEDpySCHEDis a program for planning and scheduling very long baseline interferometry (VLBI) observations conducted by different networks such as the European VLBI Network (EVN), the Very Long Baseline Array (VLBA), the High Sensitivity Array (HSA), the Global VLBI, the Australian Long Baseline Array (LBA), or the Korean VLBI Network (KVN).pySCHEDproduces the standard files that need to be distributed to the different telescopes and correlators for VLBI observations and operations.pySCHEDis built upon theNRAO SCHEDprogram developed by Craig Walker at NRAO, and adds unique features:Central catalog management on GitHub. The version controlled catalogs provide full access to the change history of each catalog file. By default, at startup,pySCHEDalways updates the catalogs; using old/outdated catalogs is no cause for errors anymore. We note that the feature can be switched off if needed (e.g. for multi-epoch observations).Full DBBC2 scheduling support, essential for EVN observations.Since v1.8.1pySCHEDchecks for updates upon startup, informing the user of a new(er) version being available.The KEYIN file can be a template schedule with executable Python-code in it. This could simplify scheduling standard observations.Can generate VEX1 as well as VEX2 output.Plotting is now done through Python'smatplotliblibrary, making it easier to control/enhance and/or implement different plots.Getting startedTo learn how to write a scheduling file (.key) that can be used to generate the observing files (.vexfile) withpySCHED, you can follow the User Guide at theEVN Scheduling Page. This documentaion is focused on observations with the European VLBI Network (EVN). For a more extended documentation on how to write the scheduling files, please take a look at the generalNRAO SCHED User Manual.Once the.keyfile is prepared,pySCHEDcan generate the scheduling files. The basic operations can be conducted by running:sched.py[-p]-k{keyfile}where the optional parameter-pretrieves the graphical mode in order to be able to make plots about the observation.InstallationDependeciesPython (>= 3.6).A Fortran compiler.NumPy (>= 1.16).Git.PyQt5 dependenciespySCHEDuses PyQt5 for its GUI. Since version 5.12, PyQt5 has external dependencies that are not automatically installed. Many systems have these dependencies installed, seethis discussion pageif you see the error messageCannot load backend 'Qt5Agg' which requires the 'qt5' interactive framework, as 'headless' is currently runningfor details.conda (recommended)Usingcondais the easiest installation method. This package manager is available for downloadhere. After installingconda, downloadthisYAML file, which describes a conda environment including all mentioned dependencies andpySCHED. To use it:condaenvcreate-fpySCHED.yaml
condaactivatepySCHEDpipIf you want to installpySCHEDsystem wide,pipcan be used directly:sudopip3installnumpy
sudopip3installpythonSCHEDpip3is included in most python3 installations, otherwise it can be installed with:sudoapt-getinstallpython3-pipNumPy version >= 1.24 and installing from sourceNumPy version 1.24.0 introduced a bug that caused the wrapper to Fortran arrays, that is created on install, to have the wrong dimensions in some cases. This bug was fixed in version 1.24.3. However, this newer version of NumPy requires code changes inpySCHEDthat in turn only work for NumPy version >= 1.24.Since NumPy version >= 1.24.3 is not ubiquitous available yet, we have chosen to make the default install ofpySCHEDrequire a version < 1.24. If you wish to usepySCHEDwith NumPy >= 1.24.3, you can do so by installingpySCHEDfrom source. To do this, clone thepySCHEDrepository, checkout thenumpy-1.24.3branch and run the install setup command:gitclonehttps://github.com/jive-vlbi/sched.gitpySCHEDcdpySCHED
gitcheckoutnumpy-1.24.3
pipinstall.Notice the changedpip installcommand. If thepySCHED.yamlfile is used to create a conda environment, remove these lines from the file:-pip:-pythonSCHEDadapt the NumPy version requirement as desired and run thepip install .command after activating the pySCHED conda environment.Known issuesIf you are encountering issues (both during installation or while running) with pySCHED, please check theDiscussions page. We are summarizing here the most-common problems and how to solve them.UpdateThe command to update pySCHED is:sudopip3install--upgradepythonSCHEDOr when using a conda installation:condaactivatepySCHED
pipinstall--upgradepythonSCHEDUsageAfter executing either thepiporcondainstallation method, the executablesched.pyshould be available in your$PATH.One of the features ofpySCHEDis that the catalog files will be downloaded/updated on start-up ofsched.py. This allows for the catalog files to be updated separate from the pySCHED release cycle. The files will be installed in~/.pysched.$SCHEDwill be set to this directory inpySCHEDif not otherwise specified. The process of downloading and updating requires the version control softwaregitto be installed and available in the$PATH. On most GNU/Linux systems,gitwill be available. If it is not, it can be installed with:sudoapt-getinstallgitUsing pySCHED within a SCHED environmentThe aforementioned usage can potentially generate some issues when pySCHED runs in an environment where the variable$SCHEDis set for the NRAO SCHED program. If$SCHEDis indeed set to the path that points to the NRAO SCHED directory, then pySCHED will read the catalogs under that directory. In this case, pySCHED will not use the most up-to-date catalogs and may fail to schedule experiments requiring the latest updates.We therefore recommend to unset this variable before running pySCHED (which would then use the default~/.pyscheddirectory) or to be sure the catalogs under the$SCHEDdirectory are proficient to schedule your experiment.Release historyv1.2.0 (2019-09-27): Merge with SCHED release 11.5.v1.2.1 (2019-10-18): Bug fixes for readline and matplotlib version.v1.3.0 (2019-11-19): Added SCANEXPS keyword to signal intent in VEX2 files. To make that work, Fortran function leading to calls of SCNDUP are translated to Python.v1.4.0 (2019-12-13): Added 'eMERL' value to DAR keyword, to enable eMERLIN out-station automatic IF and BBC assignment.v1.5.0 (2020-02-25): Improved error/warning messages.v1.5.1 (2020-03-24): Updated the error message for a missing '/'.v1.5.2 (2020-03-26): Update version restriction to PyQt version.v1.5.3 (2020-04-02): Handle changes made in matplotlib version 3.2.v1.6.0 (2020-05-12): Catalog updates for May/June session and plot improvements.v1.7.0 (2020-05-18): Include pySCHED version in command line and interactive help text.v1.8.0 (2020-05-19): Do a version check on start-up.v1.8.1 (2020-05-20): Include README.md in distribution, it is required for installation.v1.8.2 (2020-05-27): Fixed update catalog writing to an unopened log file.v1.9.0 (2020-06-09): Overhaul of the README.v1.10.0 (2020-06-22): SCHED 11.6 merged into pySCHED.v1.11.0 (2020-07-11): Add warning message on empty KEYIN input record.v1.12.0 (2020-07-21): Runtime improved by about 30%.v1.12.1 (2020-09-10): Bug fix, continuous recording warning would trigger too often.v1.13.0 (2020-10-05): Allow double bandwidth for eMERLIN if 1 bits sampling is used.v1.13.1 (2020-10-07): Bug(s) in exit.c function triggered compiler error. Turned out to be unused code, so removed from compilation list.v1.13.2 (2020-10-14): Update code to support matplotlib version 3.3.v1.14.0 (2020-10-23): Updated legend layout of uptime plot and added a help button in the plot toolbar.v1.14.1 (2020-11-05): pySCHED uses string formatting introduced in python version 3.6. Make this requirement explicit.v1.14.2 (2020-11-06): Fortran index was used to index Python array, causing an error when 16 BBCs were used.v1.15.0 (2020-11-23): Cleared up confusion about the starting day of time based plots.v1.16.0 (2021-01-12): Now compatible with matplotlib 3.3.3 and advertised the GitHub page in the start-up message.v1.16.1 (2021-01-21): Bug fix for XY plots.v1.17.0 (2021-03-29): Fix deprecations warned for by matplotlib 3.4.v1.18.0 (2021-05-21): Updates to plot UI for smaller desktop windows.v1.19.0 (2021-07-09): Add polarization comment for frequency channels in VEX file.v1.19.1 (2021-10-19): Bug fixes for BITSTREAMS section generation and deprecated functionality in Matplotlib that caused a crash setting axis properties.v1.20.0 (2021-11-01): Add option to display slew times in the uptime plot.v1.20.1 (2021-11-04): Escape TeX special characters in Matplotlib plots titles and labels, when Matplotlib is configured to use LaTex to display text.v1.21.0 (2021-11-17): Fix deprecations warned for by matplotlib 3.5.v1.22.0 (2022-01-14): Add 'JIVE-e-VLBI' as possible target correlator.v1.23.0 (2022-04-28): This version introduces three changes:Added extra version information to the VEX file.Search for a given setup file in the $SCHED/setups directory, if it does not include a path and is not found in the current directory.Replace deprecated distutils.version.LooseVersion with packaging.version.parse.v1.24.0 (2022-05-13): Incorporate EVN SCHED patches for wrap zone into pySCHED.v1.25.0 (2022-09-30): Raise the level at which warnings about sources too close to the sun are printed to standard output and make some of the thresholds used configurable.v1.25.1 (2022-10-06): Require a newer version of NumPy. In earlier version calling round(numpy.float) would return a float, which caused a problem in string formatting.v1.25.2 (2023-01-11): F2py from NumPy version 1.24 creates different data block wrappers, require an earlier version of NumPy for now.v1.25.3 (2023-02-23): Matplotlib version 3.7.0 deprecated the attribute legendHandles for legend_handles. This version supports both to suppress the warning message.v1.25.4 (2023-03-29): Fix a bug in the setup script NumPy version specification.v1.25.5 (2023-04-05): Updates to VEX2 writing routines (PROCEDURES, pointing_sector and datastream).v1.25.6 (2023-04-12): Two bug fixes:The OMS file writing Fortran function would write out of string boundaries for setups with more than 31 channels, into the setup file name. Only print the first 31 channels.Update the Python wrap zone writing equivalent to the changes to the Fortran code introduced in 1.24.0.v1.26.0 (2023-05-03): Skip writing pointing_sector lines in the $ANTENNA block of the VEX files for KVN stations.v1.26.1 (2023-09-19): Bug fix: the 3rd and 6th cable wrap zones would use the lower instead of upper limit of the first axis.v1.26.2 (2023-12-04): Bug fix in the Fortran code for wrap zones: a rare warning message had the wrong number of formatting parameters.ContactpySCHEDis maintained at theJoint Institute for VLBI ERIC (JIVE). You can reach the maintainers atpysched@jive.eu.AcknowledgementThis project has received funding from the European Union’s Horizon 2020 research and innovation programme under grant agreement No 730884.