docstr: Some sanity checks on the input, the high_freq and low_freq arguments are mutually exclusive
docstr_tok: ["Some","sanity","checks","on","the","input",",","the","high_freq","and","low_freq","arguments","are","mutually","exclusive"]
code: def _verify_series(
      series: TimeSeries,
      high_freq: Optional[str] = None,
      low_freq: Optional[str] = None,
  ):
      """Some sanity checks on the input, the high_freq and low_freq arguments are mutually exclusive"""
      if not isinstance(series.time_index, pd.DatetimeIndex):
          raise_log(
              ValueError(
                  "MIDAS input series must have a pd.Datetime index"
              ),
              logger,
          )
  
      series_freq_str = series.freq_str
      input_freq = [series_freq_str]
      # flexibility on anchoring
      if "-" in series_freq_str:
          input_freq.append(series_freq_str.split("-")[0])
  
      if high_freq is not None and high_freq not in input_freq:
          raise_log(
              ValueError(
                  f"The frequency string of the series to transform must be identical to the fitted one, expected "
                  f"{high_freq} but received {series_freq_str}."
              ),
              logger=logger,
          )
      if low_freq is not None and low_freq not in input_freq:
          raise_log(
              ValueError(
                  f"The frequency string of the series to inverse-transform must be identical to the fitted one, "
                  f"expected {low_freq} but received {series_freq_str}."
              ),
              logger=logger,
          )
  
file_path: darts/darts/dataprocessing/transformers/midas.py
imports: from typing import Any, Dict, List, Mapping, Optional, Sequence, Union
  import numpy
  import pandas
  from darts import TimeSeries
  from darts.dataprocessing.transformers import FittableDataTransformer, InvertibleDataTransformer
  from darts.logging import get_logger, raise_log
  from darts.timeseries import _finite_rows_boundaries
  from darts.utils.timeseries_generation import generate_index
label_desc: Use image node_id 5 for calling the MIDAS obj's underlying member method code with example usage: obj._verify_series(series, high_freq, low_freq) without return types