docs: def map_query(self, variables=None, evidence=None):
          """
          MAP Query method using belief propagation.
  
          Note: When multiple variables are passed, it returns the map_query for each
          of them individually.
  
          Parameters
          ----------
          variables: list
              list of variables for which you want to compute the probability
          evidence: dict
              a dict key, value pair as {var: state_of_var_observed}
              None if no evidence
  
          Examples
          --------
          >>> from pgmpy.factors.discrete import TabularCPD
          >>> from pgmpy.models import BayesianModel
          >>> from pgmpy.inference import BeliefPropagation
          >>> bayesian_model = BayesianModel([('A', 'J'), ('R', 'J'), ('J', 'Q'),
          ...                                 ('J', 'L'), ('G', 'L')])
          >>> cpd_a = TabularCPD('A', 2, [[0.2], [0.8]])
          >>> cpd_r = TabularCPD('R', 2, [[0.4], [0.6]])
          >>> cpd_j = TabularCPD('J', 2,
          ...                    [[0.9, 0.6, 0.7, 0.1],
          ...                     [0.1, 0.4, 0.3, 0.9]],
          ...                    ['R', 'A'], [2, 2])
          >>> cpd_q = TabularCPD('Q', 2,
          ...                    [[0.9, 0.2],
          ...                     [0.1, 0.8]],
          ...                    ['J'], [2])
          >>> cpd_l = TabularCPD('L', 2,
          ...                    [[0.9, 0.45, 0.8, 0.1],
          ...                     [0.1, 0.55, 0.2, 0.9]],
          ...                    ['G', 'J'], [2, 2])
          >>> cpd_g = TabularCPD('G', 2, [[0.6], [0.4]])
          >>> bayesian_model.add_cpds(cpd_a, cpd_r, cpd_j, cpd_q, cpd_l, cpd_g)
          >>> belief_propagation = BeliefPropagation(bayesian_model)
          >>> belief_propagation.map_query(variables=['J', 'Q'],
          ...                              evidence={'A': 0, 'R': 0, 'G': 0, 'L': 1})
          """
          # TODO:Check the note in docstring. Change that behavior to return the joint MAP
          if not variables:
              variables = set(self.variables)
  
          final_distribution = self._query(variables=variables, operation='marginalize', evidence=evidence)
  
          # To handle the case when no argument is passed then
          # _variable_elimination returns a dict.
          argmax = np.argmax(final_distribution.values)
          assignment = final_distribution.assignment([argmax])[0]
  
          map_query_results = {}
          for var_assignment in assignment:
              var, value = var_assignment
              map_query_results[var] = value
  
          if not variables:
              return map_query_results
          else:
              return_dict = {}
              for var in variables:
                  return_dict[var] = map_query_results[var]
              return return_dict