class_docstr: Label based node affinity scheduling strategy
  
  scheduling_strategy=NodeLabelSchedulingStrategy({
        "region": In("us"),
        "gpu_type": Exists()
  })
class_docstr_tok: ["Label","based","node","affinity","scheduling","strategy","scheduling_strategy=NodeLabelSchedulingStrategy","(","{","``","region","''",":","In","(","``","us","''",")",",","``","gpu_type","''",":","Exists","(",")","}",")"]
code: def _check_usage(self):
      if not (self.hard or self.soft):
          raise ValueError(
              "The `hard` and `soft` parameter "
              "of NodeLabelSchedulingStrategy cannot both be empty."
          )
  
imports: from typing import Dict, Union, Optional, TYPE_CHECKING
  from ray.util.annotations import PublicAPI
label_desc: Use image node_id 2 for calling the NodeLabelSchedulingStrategy obj's underlying member method code with example usage: obj._check_usage() without return types