class_docstr: User-facing API for accessing the NASBench dataset.
docstr: Checks the validity of the model_spec.
  
  For the purposes of benchmarking, this does not increment the budget
  counters.
  
  Args:
    model_spec: ModelSpec object.
  
  Returns:
    True if model is within space.
docstr_tok: ["Checks","the","validity","of","the","model_spec",".","For","the","purposes","of","benchmarking",",","this","does","not","increment","the","budget","counters",".","Args",":","model_spec",":","ModelSpec","object",".","Returns",":","True","if","model","is","within","space","."]
code: def is_valid(self, model_spec):
      """Checks the validity of the model_spec.
  
      For the purposes of benchmarking, this does not increment the budget
      counters.
  
      Args:
        model_spec: ModelSpec object.
  
      Returns:
        True if model is within space.
      """
      try:
          self._check_spec(model_spec)
      except OutOfDomainError:
          return False
  
      return True
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import copy
  import random
  import time
  import shelve
  import hashlib
  import _pickle
  import numpy
label_desc: Use image node_id 3 for calling the NASBench obj's underlying member method code with example usage: obj.is_valid(model_spec) and returns: True, False