PSL TOOLSv1.0
REFERENCE MANUAL

CONTENTS


INTRODUCTION

The PSL Tools from the Perceptual Science Laboratory at the University of California Santa Cruz is an extension to the CSLU Speech Toolkit and it's RAD (Rapid Application Developer). It adds objects to the RAD for designing and conducting perceptual experiments. There are three objects: Expcontrol, Stimulus and Response. Theese are designed to work together, but they can also be used individually.

EXPCONTROL

The Experiment Control Object (Expcontrol) is intended to be connected with other objects in a loop. On each cycle (or trial), it will assign values to a set of user-defined variables (the stimulus variables), much like the list builder object. On each cycle it will also read the values of one or more user defined variables (the response variables). After each trial it will write the values of the stimulus and response variables to a file.

Variable combination

The experimenter specifies the names of the stimulus variables, and a set of values for each variable. The Expcontrol will then use these values to create a stimuli block (a set  of combinations, each combination corresponds to one trial). For generation of the blocks, the user can choose between factorial design and expanded factorial design. Factorial design means that all possible combinations of the variable values are taken. If we have two variables, with N and M values respectively, then the total number of combinations in the factorial design will be N x M.
Expanded factorial design produces all combinations of the factorial, plus each value in isolation (achieved by pairing each value from each of the variables with - (dash) in the other variables). In the two variable case above, the total number of combinations in the expanded factorial design will be N x M + N + M.
The stimuli set can be viewed in a matrix form with one variable horizontally and one vertically, and all existing combinations marked with "x".

Blocks and Randomization

When the experment is run, expcontrol generates a stimulus list consisting of a user specified number of blocks. The trials within each block can be randomized. Three randomizaion options are available: shuffling (sampling without replacement), sampling (with replacement), or none (no randomization). Optionally, a fixed seed can be supplied to the random number generator. This is useful when a particular experiment is to be reproduced exactly.
Randomization is done individually within each block. The resulting stimulus list can be viewed from the setup dialog.

Logfile and Datafile

Each experiment has an associated logfile, and one or more datafiles. The experimenter must provide a logfile name, preferably in an empty directory, before the experiment is run for the first time. Each time the experiment is run, expcontrol will write an entry to the logfile, and create a new datafile in which it will store the results of the experminet. The logfile entry consists of the following:
  • date and time the experiment was started
  • name of the computer
  • name of the datafile where the results are stored
  • any subject data that was asked for
The datafile is named automatically by taking the name of the logfile, appending a three-digit sequence number (starting at 000) and the extension .dat (Example: If the logfile name is myexperiment.log then the third data file will be named myexperiment002.dat)
There are two possible formats for the datafile, both are in ASCII. The first format has a header giving the names of all data items, followed by a blank line, followed by all data in tab-delimited form in one line per trial. The second format writes multiple lines per trial, it puts the name and the value of each variable on a new line, with a blank line between trials. Variable names are prefixed by either stim:, resp: or time: depending on wether it refers to a stimulus variabel, a response variable or a reaction time. Reaction times are given in milliseconds. 

In the examples below two stimulus variables (s0, s1) along with one response variable (r0) is assumed. The one line per trial format is:
 
trial block stim:s0 stim:s1  resp:r0 time:r0
           
1 1 val val val val
2 1 val val val val
...          

The multiple lines per trial format is:
 
trial 1
block 1
stim:s0 val
stim:s1 val
resp:r0 val
time:r0 val
   
trial 2
block 1
stim:s0 val
stim:s1 val
resp:r0 val
time:r0 val
...  


STIMULUS

The stimulus object provides a facility for presenting a stimulus of audiovisual speech or a recorded sound. The stimulus object does two things: it presents the desired stimulus, and it stores the time for the start of the presentation in the user variable e(stime). The stimulus object is designed to work with the other PSL Tools, and is adequate for many common tasks, but the experimenter may choose to use another object to present the stimulus, such as the media- or the generic object. If the stimulus object is not used and reaction time is to be recorded in the experiment, the user variable e(stime) will have to be set explicitly, for example by adding the line
set e(stime) [clock clicks]
in a post- or pre action, which may or may not provide sufficient resolution.
The stimulus object allows the experimenter to select one of the following types of stimuli:

Text-to-Speech

Causes a text string to be spoken by the audio-visual speech synthesis (Festival+Baldi). The string may contain user variables.

AV-prompt

Auditory and visual speech synthesis, with independent control over the two modalities. Allows the user to specify separate strings for auditory and visual generation. The strings may contain user variables. Gaussian noise can be added to the acoustic speech to obtain a desired signal-to-noise ratio (SNR) in decibels. The SNR may be specified by a user variable. The procedure used for adding noise is as follows: the energy of the synthesized speech (Esig) is measured, and noise is generated at a level given by
Enoise = Esig - SNR
and mixed with the speech signal.

Recorded Prompt

Causes a pre-recorded wavefile to be played. The name of the wavefile may contain user variables.

Animated Recorded Prompt

Generates synthetic visual speech, synchronized with recorded audiory speech. The string specified in the Text-to-Speech field is used in combination with the wavefile specified under "Recorded Prompt" with a foreced alignment procedure to generate phoneme labels and durationds that govern the generation of synthetic visual speech. Both the text-to-speech string and the wavefile name may contain user variables.

RESPONSE

The response object provdes an easy way to collect the subject's response through keyboard, mouse or voice. It waits for the response to occur and then sets one or more variables to the recieved response and the time.
The response object alows the experimenter to select one of the following types of response:

Buttons

...

Keys

...

Typed

...

Voice

...

Home | Reference Manual | Tutorial | Download

This page was  by Jonas Beskow