Makes inferences for entities, feature views, odfvs, and feature services.
(
self,
data_sources_to_update: List[DataSource],
entities_to_update: List[Entity],
views_to_update: List[FeatureView],
odfvs_to_update: List[OnDemandFeatureView],
sfvs_to_update: List[StreamFeatureView],
feature_services_to_update: List[FeatureService],
lvs_to_update: Optional[List[LabelView]] = None,
)
| 922 | ) |
| 923 | |
| 924 | def _make_inferences( |
| 925 | self, |
| 926 | data_sources_to_update: List[DataSource], |
| 927 | entities_to_update: List[Entity], |
| 928 | views_to_update: List[FeatureView], |
| 929 | odfvs_to_update: List[OnDemandFeatureView], |
| 930 | sfvs_to_update: List[StreamFeatureView], |
| 931 | feature_services_to_update: List[FeatureService], |
| 932 | lvs_to_update: Optional[List[LabelView]] = None, |
| 933 | ): |
| 934 | """Makes inferences for entities, feature views, odfvs, and feature services.""" |
| 935 | lvs_to_update = lvs_to_update or [] |
| 936 | |
| 937 | update_data_sources_with_inferred_event_timestamp_col( |
| 938 | data_sources_to_update, self.config |
| 939 | ) |
| 940 | |
| 941 | update_data_sources_with_inferred_event_timestamp_col( |
| 942 | [ |
| 943 | view.batch_source |
| 944 | for view in views_to_update |
| 945 | if view.batch_source is not None |
| 946 | ], |
| 947 | self.config, |
| 948 | ) |
| 949 | |
| 950 | update_data_sources_with_inferred_event_timestamp_col( |
| 951 | [ |
| 952 | view.batch_source |
| 953 | for view in sfvs_to_update |
| 954 | if view.batch_source is not None |
| 955 | ], |
| 956 | self.config, |
| 957 | ) |
| 958 | |
| 959 | update_data_sources_with_inferred_event_timestamp_col( |
| 960 | [lv.batch_source for lv in lvs_to_update if lv.batch_source is not None], |
| 961 | self.config, |
| 962 | ) |
| 963 | |
| 964 | # New feature views may reference previously applied entities. |
| 965 | entities = self._list_entities() |
| 966 | provider = self._get_provider() |
| 967 | update_feature_views_with_inferred_features_and_entities( |
| 968 | provider, |
| 969 | views_to_update, |
| 970 | entities + entities_to_update, |
| 971 | self.config, |
| 972 | ) |
| 973 | update_feature_views_with_inferred_features_and_entities( |
| 974 | provider, |
| 975 | sfvs_to_update, |
| 976 | entities + entities_to_update, |
| 977 | self.config, |
| 978 | ) |
| 979 | # We need to attach the time stamp fields to the underlying data sources |
| 980 | # and cascade the dependencies |
| 981 | update_feature_views_with_inferred_features_and_entities( |
no test coverage detected