Builds a FeatureViewIngestionTimeParameters from values in a params dict. Args: input_params: All the user-specified ingestions time parameters. Will be modified in-place to remove fields in FeatureViewIngestionTimeParameters. Returns: A FeatureViewIngestionTimeParameters contain
(
input_params: dict[str, Any] | None,
)
| 1903 | |
| 1904 | |
| 1905 | def build_ingestion_time_parameters( |
| 1906 | input_params: dict[str, Any] | None, |
| 1907 | ) -> dict[str, Any]: |
| 1908 | """Builds a FeatureViewIngestionTimeParameters from values in a params dict. |
| 1909 | |
| 1910 | Args: |
| 1911 | input_params: All the user-specified ingestions time parameters. Will be |
| 1912 | modified in-place to remove fields in FeatureViewIngestionTimeParameters. |
| 1913 | |
| 1914 | Returns: |
| 1915 | A FeatureViewIngestionTimeParameters containing information extracted from |
| 1916 | config. |
| 1917 | """ |
| 1918 | output_params = {} |
| 1919 | |
| 1920 | thinning_options = _build_thinning_options(input_params) |
| 1921 | if thinning_options: |
| 1922 | output_params['thinningOptions'] = thinning_options |
| 1923 | |
| 1924 | ranking_options = _build_ranking_options(input_params) |
| 1925 | if ranking_options: |
| 1926 | output_params['rankingOptions'] = ranking_options |
| 1927 | |
| 1928 | if input_params: |
| 1929 | raise ee_exception.EEException( |
| 1930 | 'The following keys are unrecognized in the ingestion parameters:' |
| 1931 | f' {list(input_params.keys())}' |
| 1932 | ) |
| 1933 | return output_params |
| 1934 | |
| 1935 | |
| 1936 | def _create_export_task(config: dict[str, Any], task_type: Task.Type) -> Task: |
no test coverage detected