class_docstr: Encapsulate PyJAGS specific logic.
class_docstr_tok: ["Encapsulate","PyJAGS","specific","logic","."]
docstr: Convert all available data to an InferenceData object.
docstr_tok: ["Convert","all","available","data","to","an","InferenceData","object","."]
code: def to_inference_data(self):
      """Convert all available data to an InferenceData object."""
      # obs_const_dict = self.observed_and_constant_data_to_xarray()
      # predictions_const_data = self.predictions_constant_data_to_xarray()
      save_warmup = self.save_warmup and self.warmup_iterations > 0
      # self.posterior is not None
  
      idata_dict = {
          "posterior": self.posterior_to_xarray(),
          "prior": self.prior_to_xarray(),
          "log_likelihood": self.log_likelihood_to_xarray(),
          "save_warmup": save_warmup,
      }
  
      return InferenceData(**idata_dict)
  
imports: import typing
  from collections import OrderedDict
  from collections.abc import Iterable
  import numpy
  import xarray
  from .inference_data import InferenceData
  from ..rcparams import rcParams
  from .base import dict_to_dataset
label_desc: Use image node_id 6 for calling the PyJAGSConverter obj's underlying member method code with example usage: obj.to_inference_data() and returns: InferenceData