MediaGibbs
**********

class psynet.trial.media_gibbs.AudioGibbsNetwork(*args, **kwargs)

   Bases: "MediaGibbsNetwork"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   full

      Whether the network is currently full

   id

      a unique number for every entry. 1, 2, 3 and so on...

   max_size

      How big the network can get, this number is used by the full()
      method to decide whether the network is full

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   role

      The role of the network. By default dallinger initializes all
      networks as either "practice" or "experiment"

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "network".
      This allows subclassing.

   vars

class psynet.trial.media_gibbs.AudioGibbsNode(*args, **kwargs)

   Bases: "MediaGibbsNode"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   network

      the network the node is in

   network_id

      the id of the network that this node is a part of

   participant

      the participant the node is associated with

   participant_id

      the id of the participant whose node this is

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "node". This
      allows subclassing.

   vars

class psynet.trial.media_gibbs.AudioGibbsTrial(*args, **kwargs)

   Bases: "MediaGibbsTrial"

   complete

      Whether the trial has been completed (i.e. received a response
      from the participant). It is set once all of "show_trial()"'s
      pages have ended, before "show_feedback()", and also when a
      barrier's release ends the trial's page in "waiting_logic"
      before it is answered, in which case the trial is failed with
      "failed_reason="interrupted_by_release"", not finalized, and
      gets no "show_feedback()". The user should not typically change
      this directly.

   creation_time

      the time at which the Network was created.

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   group_round

      The "SyncGroupRound" this trial was played in, shared with the
      trials of the other members in the round, or "None" for
      ungrouped trials. Its "var" holds the group's results for the
      round, and "group_round.trials" the partners' trials.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   position

      Zero-based creation position among all trials from this trial
      maker for the participant, or, for trials made by "Trial.cue()",
      among the participant's trials in the same module.

   show_trial(experiment, participant)

      Returns a "Page" object, or alternatively a list of such
      objects, that solicits an answer from the participant.

      Parameters:
         * **experiment** -- An instantiation of
           "psynet.experiment.Experiment", corresponding to the
           current experiment.

         * **participant** -- An instantiation of
           "psynet.participant.Participant", corresponding to the
           current participant.

   sync_group_id

      The group of the trial maker's (or, for cued trials, the trial
      class's) "sync_group_type" that the participant was in when the
      trial was created, kept after the group ends.

   sync_group_outcome

      when the trial maker prepares the group's next trials,
      ""stayed"" is written on the complete trials of the members
      still in the group. "None" while nothing has happened yet, and
      for ungrouped trials.

      Type:
         How the group's round ended for this player, for a trial in a
         group's round ("group_round"), one of "SyncGroupOutcome". It
         is written during the trial's pages, that is, before
         "complete" is set

      Type:
         ""stayed"" once a "GroupBarrier" in those pages, such as in
         "show_trial()", releases the group with the player in it,
         after which it doesn't change. Before that, why the player
         left the group, one of the reasons of "remove_participant()",
         such as ""late"", ""waited_too_long"", ""left_experiment"" or
         ""group_dissolved"" or ""removed_by_experimenter"". Leaving
         after a release, for example by being late at a later
         barrier, shows in "sync_group_removal_reason()" and in the
         "left" of the next barrier's "on_release" instead. Barriers
         and departures after the trial's pages, such as in
         "show_feedback()" or between rounds, write nothing. The
         exception is a trial maker's round that no barrier in the
         trial's pages released

   sync_group_role

      The participant's role in "sync_group_id", if a Regrouper gave
      one.

   sync_group_round

      Which round of "sync_group_id" this trial belongs to, counted
      from 0. A member who joined the group late shares the group's
      numbers. In a trial maker, a leader told to wait gives the group
      no trials, so the followers wait too and no number is used up.
      It equals the "number" of "group_round".

   sync_group_round_id

      ID of "group_round".

   time_of_death

      the time at which failing occurred

   type

   vars

class psynet.trial.media_gibbs.AudioGibbsTrialMaker(*, id_, trial_class, node_class, network_class=None, chain_type, expected_trials_per_participant, max_trials_per_participant=None, max_trials_per_block=None, max_nodes_per_chain=None, chains_per_participant=None, chains_per_experiment=None, trials_per_node=1, n_repeat_trials=0, target_n_participants=None, n_participants_completion='experiment', start_nodes=None, block_order='random', chain_order='random', interleave_chains=True, balance_across_chains=None, check_performance_at_end=False, check_performance_every_trial=False, recruit_mode=None, fail_trials_on_premature_exit=False, fail_trials_on_participant_performance_check=False, propagate_failure=True, wait_for_networks=False, allow_revisiting_networks_in_across_chains=False, assets=None, choose_participant_group=None, sync_group_type=None, sync_group_max_wait_time=<class 'psynet.utils.NoArgumentProvided'>, sync_group_max_wait_action='fail', sync_group_late_after=None, sync_group_late_action=None, sync_group_also_leave=None, sync_group_waiting_message=None, sync_group_newcomer_max_wait=None)

   Bases: "MediaGibbsTrialMaker"

class psynet.trial.media_gibbs.HtmlGibbsNetwork(*args, **kwargs)

   Bases: "MediaGibbsNetwork"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   full

      Whether the network is currently full

   id

      a unique number for every entry. 1, 2, 3 and so on...

   max_size

      How big the network can get, this number is used by the full()
      method to decide whether the network is full

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   role

      The role of the network. By default dallinger initializes all
      networks as either "practice" or "experiment"

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "network".
      This allows subclassing.

   vars

class psynet.trial.media_gibbs.HtmlGibbsNode(*args, **kwargs)

   Bases: "MediaGibbsNode"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   network

      the network the node is in

   network_id

      the id of the network that this node is a part of

   participant

      the participant the node is associated with

   participant_id

      the id of the participant whose node this is

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "node". This
      allows subclassing.

   vars

class psynet.trial.media_gibbs.HtmlGibbsTrial(*args, **kwargs)

   Bases: "MediaGibbsTrial"

   complete

      Whether the trial has been completed (i.e. received a response
      from the participant). It is set once all of "show_trial()"'s
      pages have ended, before "show_feedback()", and also when a
      barrier's release ends the trial's page in "waiting_logic"
      before it is answered, in which case the trial is failed with
      "failed_reason="interrupted_by_release"", not finalized, and
      gets no "show_feedback()". The user should not typically change
      this directly.

   creation_time

      the time at which the Network was created.

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   group_round

      The "SyncGroupRound" this trial was played in, shared with the
      trials of the other members in the round, or "None" for
      ungrouped trials. Its "var" holds the group's results for the
      round, and "group_round.trials" the partners' trials.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   position

      Zero-based creation position among all trials from this trial
      maker for the participant, or, for trials made by "Trial.cue()",
      among the participant's trials in the same module.

   show_trial(experiment, participant)

      Returns a "Page" object, or alternatively a list of such
      objects, that solicits an answer from the participant.

      Parameters:
         * **experiment** -- An instantiation of
           "psynet.experiment.Experiment", corresponding to the
           current experiment.

         * **participant** -- An instantiation of
           "psynet.participant.Participant", corresponding to the
           current participant.

   sync_group_id

      The group of the trial maker's (or, for cued trials, the trial
      class's) "sync_group_type" that the participant was in when the
      trial was created, kept after the group ends.

   sync_group_outcome

      when the trial maker prepares the group's next trials,
      ""stayed"" is written on the complete trials of the members
      still in the group. "None" while nothing has happened yet, and
      for ungrouped trials.

      Type:
         How the group's round ended for this player, for a trial in a
         group's round ("group_round"), one of "SyncGroupOutcome". It
         is written during the trial's pages, that is, before
         "complete" is set

      Type:
         ""stayed"" once a "GroupBarrier" in those pages, such as in
         "show_trial()", releases the group with the player in it,
         after which it doesn't change. Before that, why the player
         left the group, one of the reasons of "remove_participant()",
         such as ""late"", ""waited_too_long"", ""left_experiment"" or
         ""group_dissolved"" or ""removed_by_experimenter"". Leaving
         after a release, for example by being late at a later
         barrier, shows in "sync_group_removal_reason()" and in the
         "left" of the next barrier's "on_release" instead. Barriers
         and departures after the trial's pages, such as in
         "show_feedback()" or between rounds, write nothing. The
         exception is a trial maker's round that no barrier in the
         trial's pages released

   sync_group_role

      The participant's role in "sync_group_id", if a Regrouper gave
      one.

   sync_group_round

      Which round of "sync_group_id" this trial belongs to, counted
      from 0. A member who joined the group late shares the group's
      numbers. In a trial maker, a leader told to wait gives the group
      no trials, so the followers wait too and no number is used up.
      It equals the "number" of "group_round".

   sync_group_round_id

      ID of "group_round".

   time_of_death

      the time at which failing occurred

   type

   vars

class psynet.trial.media_gibbs.HtmlGibbsTrialMaker(*, id_, trial_class, node_class, network_class=None, chain_type, expected_trials_per_participant, max_trials_per_participant=None, max_trials_per_block=None, max_nodes_per_chain=None, chains_per_participant=None, chains_per_experiment=None, trials_per_node=1, n_repeat_trials=0, target_n_participants=None, n_participants_completion='experiment', start_nodes=None, block_order='random', chain_order='random', interleave_chains=True, balance_across_chains=None, check_performance_at_end=False, check_performance_every_trial=False, recruit_mode=None, fail_trials_on_premature_exit=False, fail_trials_on_participant_performance_check=False, propagate_failure=True, wait_for_networks=False, allow_revisiting_networks_in_across_chains=False, assets=None, choose_participant_group=None, sync_group_type=None, sync_group_max_wait_time=<class 'psynet.utils.NoArgumentProvided'>, sync_group_max_wait_action='fail', sync_group_late_after=None, sync_group_late_action=None, sync_group_also_leave=None, sync_group_waiting_message=None, sync_group_newcomer_max_wait=None)

   Bases: "MediaGibbsTrialMaker"

class psynet.trial.media_gibbs.ImageGibbsNetwork(*args, **kwargs)

   Bases: "MediaGibbsNetwork"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   full

      Whether the network is currently full

   id

      a unique number for every entry. 1, 2, 3 and so on...

   max_size

      How big the network can get, this number is used by the full()
      method to decide whether the network is full

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   role

      The role of the network. By default dallinger initializes all
      networks as either "practice" or "experiment"

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "network".
      This allows subclassing.

   vars

class psynet.trial.media_gibbs.ImageGibbsNode(*args, **kwargs)

   Bases: "MediaGibbsNode"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   network

      the network the node is in

   network_id

      the id of the network that this node is a part of

   participant

      the participant the node is associated with

   participant_id

      the id of the participant whose node this is

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "node". This
      allows subclassing.

   vars

class psynet.trial.media_gibbs.ImageGibbsTrial(*args, **kwargs)

   Bases: "MediaGibbsTrial"

   complete

      Whether the trial has been completed (i.e. received a response
      from the participant). It is set once all of "show_trial()"'s
      pages have ended, before "show_feedback()", and also when a
      barrier's release ends the trial's page in "waiting_logic"
      before it is answered, in which case the trial is failed with
      "failed_reason="interrupted_by_release"", not finalized, and
      gets no "show_feedback()". The user should not typically change
      this directly.

   creation_time

      the time at which the Network was created.

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   group_round

      The "SyncGroupRound" this trial was played in, shared with the
      trials of the other members in the round, or "None" for
      ungrouped trials. Its "var" holds the group's results for the
      round, and "group_round.trials" the partners' trials.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   position

      Zero-based creation position among all trials from this trial
      maker for the participant, or, for trials made by "Trial.cue()",
      among the participant's trials in the same module.

   show_trial(experiment, participant)

      Returns a "Page" object, or alternatively a list of such
      objects, that solicits an answer from the participant.

      Parameters:
         * **experiment** -- An instantiation of
           "psynet.experiment.Experiment", corresponding to the
           current experiment.

         * **participant** -- An instantiation of
           "psynet.participant.Participant", corresponding to the
           current participant.

   sync_group_id

      The group of the trial maker's (or, for cued trials, the trial
      class's) "sync_group_type" that the participant was in when the
      trial was created, kept after the group ends.

   sync_group_outcome

      when the trial maker prepares the group's next trials,
      ""stayed"" is written on the complete trials of the members
      still in the group. "None" while nothing has happened yet, and
      for ungrouped trials.

      Type:
         How the group's round ended for this player, for a trial in a
         group's round ("group_round"), one of "SyncGroupOutcome". It
         is written during the trial's pages, that is, before
         "complete" is set

      Type:
         ""stayed"" once a "GroupBarrier" in those pages, such as in
         "show_trial()", releases the group with the player in it,
         after which it doesn't change. Before that, why the player
         left the group, one of the reasons of "remove_participant()",
         such as ""late"", ""waited_too_long"", ""left_experiment"" or
         ""group_dissolved"" or ""removed_by_experimenter"". Leaving
         after a release, for example by being late at a later
         barrier, shows in "sync_group_removal_reason()" and in the
         "left" of the next barrier's "on_release" instead. Barriers
         and departures after the trial's pages, such as in
         "show_feedback()" or between rounds, write nothing. The
         exception is a trial maker's round that no barrier in the
         trial's pages released

   sync_group_role

      The participant's role in "sync_group_id", if a Regrouper gave
      one.

   sync_group_round

      Which round of "sync_group_id" this trial belongs to, counted
      from 0. A member who joined the group late shares the group's
      numbers. In a trial maker, a leader told to wait gives the group
      no trials, so the followers wait too and no number is used up.
      It equals the "number" of "group_round".

   sync_group_round_id

      ID of "group_round".

   time_of_death

      the time at which failing occurred

   type

   vars

class psynet.trial.media_gibbs.ImageGibbsTrialMaker(*, id_, trial_class, node_class, network_class=None, chain_type, expected_trials_per_participant, max_trials_per_participant=None, max_trials_per_block=None, max_nodes_per_chain=None, chains_per_participant=None, chains_per_experiment=None, trials_per_node=1, n_repeat_trials=0, target_n_participants=None, n_participants_completion='experiment', start_nodes=None, block_order='random', chain_order='random', interleave_chains=True, balance_across_chains=None, check_performance_at_end=False, check_performance_every_trial=False, recruit_mode=None, fail_trials_on_premature_exit=False, fail_trials_on_participant_performance_check=False, propagate_failure=True, wait_for_networks=False, allow_revisiting_networks_in_across_chains=False, assets=None, choose_participant_group=None, sync_group_type=None, sync_group_max_wait_time=<class 'psynet.utils.NoArgumentProvided'>, sync_group_max_wait_action='fail', sync_group_late_after=None, sync_group_late_action=None, sync_group_also_leave=None, sync_group_waiting_message=None, sync_group_newcomer_max_wait=None)

   Bases: "MediaGibbsTrialMaker"

class psynet.trial.media_gibbs.MediaGibbsNetwork(*args, **kwargs)

   Bases: "GibbsNetwork"

   A Network class for Media Gibbs Sampler chains. The user should
   customise this by overriding the attributes
   "synth_function_location", "vector_length", "vector_ranges", and
   optionally "granularity", "n_jobs". The user is also invited to
   override the "psynet.trial.chain.ChainNetwork.make_definition()"
   method in situations where different chains are to have different
   properties (e.g. different prompts).

   synth_function_location

      A dictionary specifying the function to use for synthesising
      stimuli. The dictionary should contain two arguments: one named
      ""module_name"", which identifies by name the module in which
      the function is contained, and one named ""function_name"",
      corresponding to the name of the function within that module.
      The synthesis function should take three arguments:

         * "vector", the parameter vector for the stimulus to be
           generated.

         * "output_path", the output path for the media file to be
           generated.

         * "chain_definition", the "context" dictionary for the
           current chain.

      Type:
         dict

   s3_bucket

      Name of the S3 bucket in which the stimuli should be stored. The
      same bucket can be reused between experiments, the UUID system
      used to generate file names should keep them unique.

      Type:
         str

   vector_length

      Must be overridden with the length of the free parameter vector
      that is manipulated during the Gibbs sampling procedure.

      Type:
         int

   vector_ranges

      Must be overridden with a list with length equal to
      "vector_length".

      Type:
         list

   n_jobs

      Integer indicating how many parallel processes should be used by
      an individual worker node when generating the stimuli. Note that
      the final number of parallel processes may be considerably more
      than this; suppose 4 networks are generating stimuli at the same
      time, and we have 3 worker nodes, then the effective number of
      parallel processes will be 3 x 3 = 9. Default is 1,
      corresponding to no parallelization.

      Type:
         int

   granularity

      When a new "MediaGibbsNode" is created, a collection of stimuli
      are generated that span a given dimension of the parameter
      vector. If "granularity" is an integer, then this integer sets
      the number of stimuli that are generated, and the stimuli will
      be spaced evenly across the closed interval defined by the
      corresponding element of "vector_ranges". If "granularity" is
      equal to ""custom"", then the spacing of the stimuli is instead
      determined by the media generation function.

      Type:
         Union[int, str]

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   full

      Whether the network is currently full

   id

      a unique number for every entry. 1, 2, 3 and so on...

   max_size

      How big the network can get, this number is used by the full()
      method to decide whether the network is full

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   role

      The role of the network. By default dallinger initializes all
      networks as either "practice" or "experiment"

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "network".
      This allows subclassing.

   vars

class psynet.trial.media_gibbs.MediaGibbsNode(*args, **kwargs)

   Bases: "GibbsNode"

   A Node class for Media Gibbs sampler chains. The user should not
   have to modify this.

   async_on_deploy()

      Called when the node is deployed to the remote server. This
      includes both deploying nodes from the local machine to the
      remote machine (e.g. when we have static stimuli that are
      preregistered in the database) and creating new nodes on the
      remote machine (e.g. when we have a chain experiment).

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   network

      the network the node is in

   network_id

      the id of the network that this node is a part of

   participant

      the participant the node is associated with

   participant_id

      the id of the participant whose node this is

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   random_sample(i)

      (Abstract method, to be overridden) Randomly samples a new value
      for the ith element of the free parameter vector. This is used
      for initialising the participant's response options.

      Parameters:
         **i** -- The index of the element that is being resampled.

      Returns:
         * *float* -- The new parameter value.

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "node". This
      allows subclassing.

   vars

class psynet.trial.media_gibbs.MediaGibbsTrial(*args, **kwargs)

   Bases: "GibbsTrial"

   A Trial class for Media Gibbs Sampler chains. The user should
   customise this by overriding the "get_prompt()" method. The user
   must also specify a time estimate by overriding the "time_estimate"
   class attribute. The user is also invited to override the
   "snap_slider", "autoplay", and "minimal_interactions" attributes.

   snap_slider

      If "True", the slider snaps to the location corresponding to the
      closest available media stimulus. If "False" (default),
      continuous values are permitted.

      Type:
         bool

   snap_slider_before_release

      If "True", the slider snaps to the closest stimulus before
      release rather than after release. This option is only available
      if the stimuli are equally spaced.

      Type:
         bool

   autoplay

      If "True", a media corresponding to the initial location on the
      slider will play as soon as the slider is ready for
      interactions. If "False" (default), the sound only plays once
      the participant first moves the slider.

      Type:
         bool

   disable_while_playing

      If *True*, the slider is disabled while the media is playing.
      Default: *False*.

      Deprecated since version 11.0.0: Use "disable_slider_on_change"
      instead.

      Type:
         bool

   disable_slider_on_change

      * "<float>": Duration for which the media slider should be
        disabled after its value changed, in seconds.

      * ""while_playing"": The slider will be disabled after a value
        change, as long as the related media is playing.

      * ""never"": The slider will not be disabled after a value
        change.

      Default: *never*.

   minimal_interactions

      Minimal interactions with the slider before the user can go to
      next trial.

      Type:
         int : default: 3

   minimal_time

      Minimal amount of time that the user must spend on the page
      before they can proceed to the next trial.

      Type:
         float : default: 3.0

   continuous_updates

      If *True*, then the slider continuously calls slider-update
      events when it is dragged, rather than just when it is released.
      In this case the log is disabled. Default: *False*.

   debug

      If "True", then the page displays debugging information about
      the current trial. If "False" (default), no information is
      displayed. Override this to enable behaviour.

      Type:
         bool

   input_type

      Defaults to *"HTML5_range_slider"*, which gives a standard
      horizontal slider. The other option currently is
      *"circular_slider"*, which gives a circular slider.

   random_wrap

      Defaults to *False*. If *True* then slider is wrapped twice so
      that there are no boundary jumps.

   complete

      Whether the trial has been completed (i.e. received a response
      from the participant). It is set once all of "show_trial()"'s
      pages have ended, before "show_feedback()", and also when a
      barrier's release ends the trial's page in "waiting_logic"
      before it is answered, in which case the trial is failed with
      "failed_reason="interrupted_by_release"", not finalized, and
      gets no "show_feedback()". The user should not typically change
      this directly.

   creation_time

      the time at which the Network was created.

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   get_prompt(experiment, participant)

      Constructs and returns the prompt to display to the participant.
      This can either be a string of text to display, or raw HTML. In
      the latter case, the HTML should be wrapped in a call to
      "markupsafe.Markup".

   group_round

      The "SyncGroupRound" this trial was played in, shared with the
      trials of the other members in the round, or "None" for
      ungrouped trials. Its "var" holds the group's results for the
      round, and "group_round.trials" the partners' trials.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   position

      Zero-based creation position among all trials from this trial
      maker for the participant, or, for trials made by "Trial.cue()",
      among the participant's trials in the same module.

   show_trial(experiment, participant)

      Returns a "Page" object, or alternatively a list of such
      objects, that solicits an answer from the participant.

      Parameters:
         * **experiment** -- An instantiation of
           "psynet.experiment.Experiment", corresponding to the
           current experiment.

         * **participant** -- An instantiation of
           "psynet.participant.Participant", corresponding to the
           current participant.

   sync_group_id

      The group of the trial maker's (or, for cued trials, the trial
      class's) "sync_group_type" that the participant was in when the
      trial was created, kept after the group ends.

   sync_group_outcome

      when the trial maker prepares the group's next trials,
      ""stayed"" is written on the complete trials of the members
      still in the group. "None" while nothing has happened yet, and
      for ungrouped trials.

      Type:
         How the group's round ended for this player, for a trial in a
         group's round ("group_round"), one of "SyncGroupOutcome". It
         is written during the trial's pages, that is, before
         "complete" is set

      Type:
         ""stayed"" once a "GroupBarrier" in those pages, such as in
         "show_trial()", releases the group with the player in it,
         after which it doesn't change. Before that, why the player
         left the group, one of the reasons of "remove_participant()",
         such as ""late"", ""waited_too_long"", ""left_experiment"" or
         ""group_dissolved"" or ""removed_by_experimenter"". Leaving
         after a release, for example by being late at a later
         barrier, shows in "sync_group_removal_reason()" and in the
         "left" of the next barrier's "on_release" instead. Barriers
         and departures after the trial's pages, such as in
         "show_feedback()" or between rounds, write nothing. The
         exception is a trial maker's round that no barrier in the
         trial's pages released

   sync_group_role

      The participant's role in "sync_group_id", if a Regrouper gave
      one.

   sync_group_round

      Which round of "sync_group_id" this trial belongs to, counted
      from 0. A member who joined the group late shares the group's
      numbers. In a trial maker, a leader told to wait gives the group
      no trials, so the followers wait too and no number is used up.
      It equals the "number" of "group_round".

   sync_group_round_id

      ID of "group_round".

   time_of_death

      the time at which failing occurred

   type

   vars

class psynet.trial.media_gibbs.MediaGibbsTrialMaker(*, id_, trial_class, node_class, network_class=None, chain_type, expected_trials_per_participant, max_trials_per_participant=None, max_trials_per_block=None, max_nodes_per_chain=None, chains_per_participant=None, chains_per_experiment=None, trials_per_node=1, n_repeat_trials=0, target_n_participants=None, n_participants_completion='experiment', start_nodes=None, block_order='random', chain_order='random', interleave_chains=True, balance_across_chains=None, check_performance_at_end=False, check_performance_every_trial=False, recruit_mode=None, fail_trials_on_premature_exit=False, fail_trials_on_participant_performance_check=False, propagate_failure=True, wait_for_networks=False, allow_revisiting_networks_in_across_chains=False, assets=None, choose_participant_group=None, sync_group_type=None, sync_group_max_wait_time=<class 'psynet.utils.NoArgumentProvided'>, sync_group_max_wait_action='fail', sync_group_late_after=None, sync_group_late_action=None, sync_group_also_leave=None, sync_group_waiting_message=None, sync_group_newcomer_max_wait=None)

   Bases: "GibbsTrialMaker"

class psynet.trial.media_gibbs.VideoGibbsNetwork(*args, **kwargs)

   Bases: "MediaGibbsNetwork"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   full

      Whether the network is currently full

   id

      a unique number for every entry. 1, 2, 3 and so on...

   max_size

      How big the network can get, this number is used by the full()
      method to decide whether the network is full

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   role

      The role of the network. By default dallinger initializes all
      networks as either "practice" or "experiment"

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "network".
      This allows subclassing.

   vars

class psynet.trial.media_gibbs.VideoGibbsNode(*args, **kwargs)

   Bases: "MediaGibbsNode"

   creation_time

      the time at which the Network was created.

   details

      a generic column for storing structured JSON data

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   network

      the network the node is in

   network_id

      the id of the network that this node is a part of

   participant

      the participant the node is associated with

   participant_id

      the id of the participant whose node this is

   property1

      a generic column that can be used to store experiment-specific
      details in String form.

   property2

      a generic column that can be used to store experiment-specific
      details in String form.

   property3

      a generic column that can be used to store experiment-specific
      details in String form.

   property4

      a generic column that can be used to store experiment-specific
      details in String form.

   property5

      a generic column that can be used to store experiment-specific
      details in String form.

   time_of_death

      the time at which failing occurred

   type

      A String giving the name of the class. Defaults to "node". This
      allows subclassing.

   vars

class psynet.trial.media_gibbs.VideoGibbsTrial(*args, **kwargs)

   Bases: "MediaGibbsTrial"

   complete

      Whether the trial has been completed (i.e. received a response
      from the participant). It is set once all of "show_trial()"'s
      pages have ended, before "show_feedback()", and also when a
      barrier's release ends the trial's page in "waiting_logic"
      before it is answered, in which case the trial is failed with
      "failed_reason="interrupted_by_release"", not finalized, and
      gets no "show_feedback()". The user should not typically change
      this directly.

   creation_time

      the time at which the Network was created.

   failed

      boolean indicating whether the Network has failed which prompts
      Dallinger to ignore it unless specified otherwise. Objects are
      usually failed to indicate something has gone wrong.

   failed_reason

      an optional reason the object was failed. If the object is
      failed as part of a cascading failure triggered from another
      object, the chain of objects will be captured in this field.

   group_round

      The "SyncGroupRound" this trial was played in, shared with the
      trials of the other members in the round, or "None" for
      ungrouped trials. Its "var" holds the group's results for the
      round, and "group_round.trials" the partners' trials.

   id

      a unique number for every entry. 1, 2, 3 and so on...

   position

      Zero-based creation position among all trials from this trial
      maker for the participant, or, for trials made by "Trial.cue()",
      among the participant's trials in the same module.

   show_trial(experiment, participant)

      Returns a "Page" object, or alternatively a list of such
      objects, that solicits an answer from the participant.

      Parameters:
         * **experiment** -- An instantiation of
           "psynet.experiment.Experiment", corresponding to the
           current experiment.

         * **participant** -- An instantiation of
           "psynet.participant.Participant", corresponding to the
           current participant.

   sync_group_id

      The group of the trial maker's (or, for cued trials, the trial
      class's) "sync_group_type" that the participant was in when the
      trial was created, kept after the group ends.

   sync_group_outcome

      when the trial maker prepares the group's next trials,
      ""stayed"" is written on the complete trials of the members
      still in the group. "None" while nothing has happened yet, and
      for ungrouped trials.

      Type:
         How the group's round ended for this player, for a trial in a
         group's round ("group_round"), one of "SyncGroupOutcome". It
         is written during the trial's pages, that is, before
         "complete" is set

      Type:
         ""stayed"" once a "GroupBarrier" in those pages, such as in
         "show_trial()", releases the group with the player in it,
         after which it doesn't change. Before that, why the player
         left the group, one of the reasons of "remove_participant()",
         such as ""late"", ""waited_too_long"", ""left_experiment"" or
         ""group_dissolved"" or ""removed_by_experimenter"". Leaving
         after a release, for example by being late at a later
         barrier, shows in "sync_group_removal_reason()" and in the
         "left" of the next barrier's "on_release" instead. Barriers
         and departures after the trial's pages, such as in
         "show_feedback()" or between rounds, write nothing. The
         exception is a trial maker's round that no barrier in the
         trial's pages released

   sync_group_role

      The participant's role in "sync_group_id", if a Regrouper gave
      one.

   sync_group_round

      Which round of "sync_group_id" this trial belongs to, counted
      from 0. A member who joined the group late shares the group's
      numbers. In a trial maker, a leader told to wait gives the group
      no trials, so the followers wait too and no number is used up.
      It equals the "number" of "group_round".

   sync_group_round_id

      ID of "group_round".

   time_of_death

      the time at which failing occurred

   type

   vars

class psynet.trial.media_gibbs.VideoGibbsTrialMaker(*, id_, trial_class, node_class, network_class=None, chain_type, expected_trials_per_participant, max_trials_per_participant=None, max_trials_per_block=None, max_nodes_per_chain=None, chains_per_participant=None, chains_per_experiment=None, trials_per_node=1, n_repeat_trials=0, target_n_participants=None, n_participants_completion='experiment', start_nodes=None, block_order='random', chain_order='random', interleave_chains=True, balance_across_chains=None, check_performance_at_end=False, check_performance_every_trial=False, recruit_mode=None, fail_trials_on_premature_exit=False, fail_trials_on_participant_performance_check=False, propagate_failure=True, wait_for_networks=False, allow_revisiting_networks_in_across_chains=False, assets=None, choose_participant_group=None, sync_group_type=None, sync_group_max_wait_time=<class 'psynet.utils.NoArgumentProvided'>, sync_group_max_wait_action='fail', sync_group_late_after=None, sync_group_late_action=None, sync_group_also_leave=None, sync_group_waiting_message=None, sync_group_newcomer_max_wait=None)

   Bases: "MediaGibbsTrialMaker"
