code: def _is_instance(self, triple):
          
          subj, pred, obj = triple
          input_pred_ns = self._namespace_from_uri(self._expand_qname(pred))
          triples = self.graph.triples(
              (subj, rt.URIRef(self.schema_def.lexicon['type']), None)
          )
          if triples:
              for tr in triples:
                  triple_obj_ns = self._namespace_from_uri(
                      self._expand_qname(tr[2]))
                  if input_pred_ns == triple_obj_ns:  # match namespaces
                      return tr[2]
docs: helper, returns the class type of subj