class_docstr: Activation generator for the KDD99 dataset.
  
  This uses the KDD99 dataset from sklearn. It is automatically loaded when we
  try to train models, so no data downloading is required.
  
  You can read more about it here:
  https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_kddcup99.html
  
  To see it in action, please check kdd99_discrete_example.ipynb
class_docstr_tok: ["Activation","generator","for","the","KDD99","dataset",".","This","uses","the","KDD99","dataset","from","sklearn",".","It","is","automatically","loaded","when","we","try","to","train","models",",","so","no","data","downloading","is","required",".","You","can","read","more","about","it","here",":","https",":","\/\/scikit-learn.org\/stable\/modules\/generated\/sklearn.datasets.fetch_kddcup99.html","To","see","it","in","action",",","please","check","kdd99_discrete_example.ipynb"]
docstr: Encodes categorical columns and returns them as a numpy array
  
   We first encode our categorical variables, so that they can be parsed by
   the model. Finally,
   we return the data in the form of a numpy array.
  
  Args:
    data: numpy.ndarray, parsed from load_data
  
  Returns:
    encoded_data: numpy.ndarray. Categorical variables are encoded.
docstr_tok: ["Encodes","categorical","columns","and","returns","them","as","a","numpy","array","We","first","encode","our","categorical","variables",",","so","that","they","can","be","parsed","by","the","model",".","Finally",",","we","return","the","data","in","the","form","of","a","numpy","array",".","Args",":","data",":","numpy.ndarray",",","parsed","from","load_data","Returns",":","encoded_data",":","numpy.ndarray",".","Categorical","variables","are","encoded","."]
code: def transform_data(self, data):
      """Encodes categorical columns and returns them as a numpy array
  
       We first encode our categorical variables, so that they can be parsed by
       the model. Finally,
       we return the data in the form of a numpy array.
  
      Args:
        data: numpy.ndarray, parsed from load_data
  
      Returns:
        encoded_data: numpy.ndarray. Categorical variables are encoded.
  
  
      """
      encoded_data = encode_variables(data)
      return encoded_data
  
file_path: tcav/tcav/tcav_examples/discrete/kdd99_activation_generator.py
imports: import os
  from tcav.activation_generator import DiscreteActivationGeneratorBase
  from tcav.tcav_examples.discrete.kdd99_model import encode_variables, kBytesIndices, kFloatIndices, kIntIndices
  import numpy
  import tensorflow
label_desc: Use image node_id 3 for calling the KDD99DiscreteActivationGenerator obj's underlying member method code with example usage: obj.transform_data(data) and returns: encoded_data