class_docstr: A memory backend which transfers the experiences from the rollout to the training worker using Redis Pub/Sub in
  Coach when distributed mode is used.
docstr: Undeploy the Redis Pub/Sub service in an orchestrator.
docstr_tok: ["Undeploy","the","Redis","Pub\/Sub","service","in","an","orchestrator","."]
code: def undeploy(self):
      """
      Undeploy the Redis Pub/Sub service in an orchestrator.
      """
      from kubernetes import client
  
      if self.params.deployed:
          return
  
      from kubernetes import client
  
      api_client = client.AppsV1Api()
      delete_options = client.V1DeleteOptions()
      try:
          api_client.delete_namespaced_deployment(
              self.redis_server_name,
              self.params.orchestrator_params["namespace"],
              delete_options,
          )
      except client.rest.ApiException as e:
          screen.print(
              "Got exception: %s\n while deleting redis-server", e
          )
  
      api_client = client.CoreV1Api()
      try:
          api_client.delete_namespaced_service(
              self.redis_service_name,
              self.params.orchestrator_params["namespace"],
              delete_options,
          )
      except client.rest.ApiException as e:
          screen.print(
              "Got exception: %s\n while deleting redis-server", e
          )
  
imports: import redis
  import pickle
  import uuid
  import time
  from rl_coach.memories.backend.memory import MemoryBackend, MemoryBackendParameters
  from rl_coach.core_types import Transition, Episode, EnvironmentSteps, EnvironmentEpisodes
  from rl_coach.logger import screen
label_desc: Use image node_id 5 for calling the RedisPubSubBackend obj's underlying member method code with example usage: obj.undeploy() without return types