class_docstr: A single run associated with an entity and project.
  
  Attributes:
      tags ([str]): a list of tags associated with the run
      url (str): the url of this run
      id (str): unique identifier for the run (defaults to eight characters)
      name (str): the name of the run
      state (str): one of: running, finished, crashed, killed, preempting, preempted
      config (dict): a dict of hyperparameters associated with the run
      created_at (str): ISO timestamp when the run was started
      system_metrics (dict): the latest system metrics recorded for the run
      summary (dict): A mutable dict-like property that holds the current summary.
                  Calling update will persist any changes.
      project (str): the project associated with the run
      entity (str): the name of the entity associated with the run
      user (str): the name of the user who created the run
      path (str): Unique identifier [entity]/[project]/[run_id]
      notes (str): Notes about the run
      read_only (boolean): Whether the run is editable
      history_keys (str): Keys of the history metrics that have been logged
          with `wandb.log({key: value})`
      metadata (str): Metadata about the run from wandb-metadata.json
class_docstr_tok: ["A","single","run","associated","with","an","entity","and","project",".","Attributes",":","tags","(","[","str","]",")",":","a","list","of","tags","associated","with","the","run","url","(","str",")",":","the","url","of","this","run","id","(","str",")",":","unique","identifier","for","the","run","(","defaults","to","eight","characters",")","name","(","str",")",":","the","name","of","the","run","state","(","str",")",":","one","of",":","running",",","finished",",","crashed",",","killed",",","preempting",",","preempted","config","(","dict",")",":","a","dict","of","hyperparameters","associated","with","the","run","created_at","(","str",")",":","ISO","timestamp","when","the","run","was","started","system_metrics","(","dict",")",":","the","latest","system","metrics","recorded","for","the","run","summary","(","dict",")",":","A","mutable","dict-like","property","that","holds","the","current","summary",".","Calling","update","will","persist","any","changes",".","project","(","str",")",":","the","project","associated","with","the","run","entity","(","str",")",":","the","name","of","the","entity","associated","with","the","run","user","(","str",")",":","the","name","of","the","user","who","created","the","run","path","(","str",")",":","Unique","identifier","[","entity","]","\/","[","project","]","\/","[","run_id","]","notes","(","str",")",":","Notes","about","the","run","read_only","(","boolean",")",":","Whether","the","run","is","editable","history_keys","(","str",")",":","Keys","of","the","history","metrics","that","have","been","logged","with","`","wandb.log","(","{","key",":","value","}",")","`","metadata","(","str",")",":","Metadata","about","the","run","from","wandb-metadata.json"]
docstr: Return sampled history metrics for a run.
  
  This is simpler and faster if you are ok with the history records being sampled.
  
  Arguments:
      samples : (int, optional) The number of samples to return
      pandas : (bool, optional) Return a pandas dataframe
      keys : (list, optional) Only return metrics for specific keys
      x_axis : (str, optional) Use this metric as the xAxis defaults to _step
      stream : (str, optional) "default" for metrics, "system" for machine metrics
  
  Returns:
      pandas.DataFrame: If pandas=True returns a `pandas.DataFrame` of history
          metrics.
      list of dicts: If pandas=False returns a list of dicts of history metrics.
code: def history(
      self,
      samples=500,
      keys=None,
      x_axis="_step",
      pandas=True,
      stream="default",
  ):
      """Return sampled history metrics for a run.
  
      This is simpler and faster if you are ok with the history records being sampled.
  
      Arguments:
          samples : (int, optional) The number of samples to return
          pandas : (bool, optional) Return a pandas dataframe
          keys : (list, optional) Only return metrics for specific keys
          x_axis : (str, optional) Use this metric as the xAxis defaults to _step
          stream : (str, optional) "default" for metrics, "system" for machine metrics
  
      Returns:
          pandas.DataFrame: If pandas=True returns a `pandas.DataFrame` of history
              metrics.
          list of dicts: If pandas=False returns a list of dicts of history metrics.
      """
      if keys is not None and not isinstance(keys, list):
          wandb.termerror("keys must be specified in a list")
          return []
      if (
          keys is not None
          and len(keys) > 0
          and not isinstance(keys[0], str)
      ):
          wandb.termerror("keys argument must be a list of strings")
          return []
  
      if keys and stream != "default":
          wandb.termerror("stream must be default when specifying keys")
          return []
      elif keys:
          lines = self._sampled_history(
              keys=keys, x_axis=x_axis, samples=samples
          )
      else:
          lines = self._full_history(samples=samples, stream=stream)
      if pandas:
          pandas = util.get_module("pandas")
          if pandas:
              lines = pandas.DataFrame.from_records(lines)
          else:
              print(
                  "Unable to load pandas, call history with pandas=False"
              )
      return lines
  
imports: import json
  import os
  import tempfile
  import time
  import urllib
  from typing import TYPE_CHECKING, Any, Dict, Mapping, Optional
  from wandb_gql import gql
  import wandb
  from wandb import env, util
  from wandb.apis import public
  from wandb.apis.attrs import Attrs
  from wandb.apis.internal import Api
  from wandb.apis.normalize import normalize_exceptions
  from wandb.apis.paginator import Paginator
  from wandb.apis.public.const import RETRY_TIMEDELTA
  from wandb.sdk.lib import ipython, json_util, runid
  from wandb.sdk.lib.paths import LogicalPath
label_desc: Use image node_id 23 for calling the Run obj's underlying member method code with example usage: obj.history(samples, keys, x_axis, pandas, stream) and returns: lines, list, list, list