class_docstr: This class implements basic sparql patterns.
class_docstr_tok: ["This","class","implements","basic","sparql","patterns","."]
docstr: execute query to return counts 
docstr_tok: ["execute","query","to","return","counts"]
code: def count_query(self, variable, triples):
      """execute query to return counts"""
      query = "count(%s) as %s" % (
          self.q_mark(variable),
          self.q_mark(variable),
      )
      return self.execution_template(
          variable, query, triples, self._count_tpl
      )[0]
  
imports: from __future__ import print_function
  from SPARQLWrapper import SPARQLWrapper, JSON
  from rdflib import RDF, RDFS, OWL
label_desc: Use image node_id 7 for calling the BaseSPARQL obj's underlying member method code with example usage: obj.count_query(variable, triples) and returns: self