Beispiel #1
0
 def __init__(self, input_col: str, partition_key: str, output_col: str,
              vocab_df: DataFrame):
     super().__init__()
     ExplainBuilder.build(self,
                          inputCol=input_col,
                          partitionKey=partition_key,
                          outputCol=output_col)
     self._vocab_df = vocab_df
Beispiel #2
0
    def __init__(self, input_col: str, partition_key: str, output_col: str,
                 reset_per_partition: bool):
        super().__init__()

        ExplainBuilder.build(self,
                             inputCol=input_col,
                             partitionKey=partition_key,
                             outputCol=output_col,
                             resetPerPartition=reset_per_partition)
Beispiel #3
0
    def __init__(self, partition_key: Optional[str],
                 indexed_col_names_arr: List[str], complementset_factor: int):

        super().__init__()

        # we assume here that all indices of the columns are continuous within their partition_key
        ExplainBuilder.build(self,
                             partitionKey=partition_key,
                             indexedColNamesArr=indexed_col_names_arr,
                             complementsetFactor=complementset_factor)
Beispiel #4
0
    def __init__(self,
                 input_col: str,
                 partition_key: Optional[str],
                 output_col: str,
                 use_pandas: bool = True):

        super().__init__()
        ExplainBuilder.build(self,
                             inputCol=input_col,
                             partitionKey=partition_key,
                             outputCol=output_col)
        self._use_pandas = use_pandas
Beispiel #5
0
    def __init__(self,
                 input_col: str,
                 partition_key: Optional[str],
                 output_col: str,
                 per_group_stats: Union[DataFrame, Dict[str, float]],
                 use_pandas: bool = True):

        super().__init__()
        ExplainBuilder.build(self,
                             inputCol=input_col,
                             partitionKey=partition_key,
                             outputCol=output_col)
        self._per_group_stats = per_group_stats
        self._use_pandas = use_pandas
Beispiel #6
0
 def __init__(self):
     super().__init__()
     ExplainBuilder.build(self, inputCol='input', partitionKey=1)
     self.setSecondPartitionKey(2)
     self.setOutputCol('output')