(self, domain: Domain)
return domain_hints
Define hints for selected/unselected features.
        Rules:
        - if context available, restore new features based on checked/unchecked
          ignore_new_features, context hint should be took into account
        - in no context, restore features based on the domain (as selected)

        Parameters
        ----------
        domain
            Data domain

        Returns
        -------
        Dictionary with hints about order and model in which each feature
        should appear
Define hints for selected/unselected features.
        Rules:
        - if context available, restore new features based on checked/unchecked
          ignore_new_features, context hint should be took into account
        - in no context, restore features based on the domain (as selected)
Define hints for selected / unselected features . Rules : - if context available restore new features based on checked / unchecked ignore_new_features context hint should be took into account - in no context restore features based on the domain ( as selected )
def restore_hints(self, domain: Domain) -> Dict[Variable, Tuple[str, int]]:
        """
        Define hints for selected/unselected features.
        Rules:
        - if context available, restore new features based on checked/unchecked
          ignore_new_features, context hint should be took into account
        - in no context, restore features based on the domain (as selected)

        Parameters
        ----------
        domain
            Data domain

        Returns
        -------
        Dictionary with hints about order and model in which each feature
        should appear
        """
        domain_hints = {}
        if not self.ignore_new_features or len(self.domain_role_hints) == 0:
            # select_new_features selected or no context - restore based on domain
            domain_hints.update(
                self._hints_from_seq("attribute", domain.attributes)
            )
            domain_hints.update(self._hints_from_seq("meta", domain.metas))
            domain_hints.update(
                self._hints_from_seq("class", domain.class_vars)
            )
        else:
            # if context restored and ignore_new_features selected - restore
            # new features as available
            d = domain.attributes + domain.metas + domain.class_vars
            domain_hints.update(self._hints_from_seq("available", d))

        domain_hints.update(self.domain_role_hints)
        return domain_hints
def restore_hints ( self , domain : Domain ) -> Dict [ Variable , Tuple [ str , int ] ] : domain_hints = { } if not self . ignore_new_features or len ( self . domain_role_hints ) == 0 : # select_new_features selected or no context - restore based on domain domain_hints . update ( self . _hints_from_seq ( "attribute" , domain . attributes ) ) domain_hints . update ( self . _hints_from_seq ( "meta" , domain . metas ) ) domain_hints . update ( self . _hints_from_seq ( "class" , domain . class_vars ) ) else : # if context restored and ignore_new_features selected - restore # new features as available d = domain . attributes + domain . metas + domain . class_vars domain_hints . update ( self . _hints_from_seq ( "available" , d ) ) domain_hints . update ( self . domain_role_hints ) return domain_hints