parameters: (self, state)
docstring: Necessary for making this object picklable
docstring_summary: Necessary for making this object picklable
docstring_tokens: Necessary for making this object picklable
function: def __setstate__(self, state):
          """Necessary for making this object picklable"""
          if not isinstance(state, dict):
              raise Exception("invalid pickle state")
  
          # compat with pre 0.21.0 CategoricalDtype change
          if "_dtype" not in state:
              state["_dtype"] = CategoricalDtype(state["_categories"], state["_ordered"])
  
          for k, v in state.items():
              setattr(self, k, v)
function_tokens: def __setstate__ ( self , state ) : if not isinstance ( state , dict ) : raise Exception ( "invalid pickle state" ) # compat with pre 0.21.0 CategoricalDtype change if "_dtype" not in state : state [ "_dtype" ] = CategoricalDtype ( state [ "_categories" ] , state [ "_ordered" ] ) for k , v in state . items ( ) : setattr ( self , k , v )