es_sfgtools.pride_tools.pride_operations module

class es_sfgtools.pride_tools.pride_operations.result(stdout, stderr)

Bases: tuple

stderr

Alias for field number 1

stdout

Alias for field number 0

es_sfgtools.pride_tools.pride_operations.rinex_to_kin(source: str, writedir: Path, pridedir: Path, site='SIT1', pride_cli_config: PrideCLIConfig = None) Tuple[Path, Path]

Generate kinematic and residual files from a RINEX file.

This function is a wrapper for the PRIDE-PPP processing tool (pdp3).

Parameters:
  • source (str) – The source RINEX file to convert.

  • writedir (Path) – The directory to write the converted kin file.

  • pridedir (Path) – The directory where PRIDE-PPP observables are stored.

  • site (str, optional) – The site name, by default “SIT1”.

  • pride_cli_config (PrideCLIConfig, optional) – The configuration for PRIDE-PPP processing. If None, uses default settings.

Returns:

The generated kin and result files as Path objects.

Return type:

Tuple[Path, Path]

Raises:
  • FileNotFoundError – If the PRIDE-PPP binary is not found in the system path.

  • FileNotFoundError – If the source RINEX file does not exist.

Examples

>>> source = Path("/path/to/NCB12450.24o") # Example RINEX file path
>>> writedir = Path("/writedir") # Directory to write the kin file
>>> pridedir = Path("/pridedir") # Directory where PRIDE-PPP observables are stored
# Get the PRIDE configuration file path
>>> pride_configfile_path = get_gnss_products(
...     rinex_path=source,
...     pride_dir=pridedir,
...     override=False,
...     source="all"
... )
# Create a PrideCLIConfig instance with the configuration file path
>>> pride_config = PrideCLIConfig(
...     sample_frequency=1,
...     override=False,
...     pride_configfile_path=pride_configfile_path,
... )
# Run PRIDE-PPP to generate kin and res files
>>> kin_file, res_file = rinex_to_kin(
...     source=source,
...     writedir=writedir,
...     pridedir=pridedir,
...     site="NCB1",
...     pride_config=pride_config,
... )
>>> kin_file
Path("writedir/kin_2024126_ncb1.kin")
>>> res_file
Path("writedir/res_2024126_ncb1.res")