Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The updated online reconstruction tools are currently on a branch of HPS Java, which you can checkout and build using a command such as:

Code Block
languagebash
themeMidnight
git clone https://github.com/JeffersonLab/hps-java
cd hps-java
git checkout online-recon-dev
mvn clean install -DskipTests

Now, you should install the online reconstruction scripts into your work area:

Code Block
languagebash
themeMidnight
# Go into online recon module within the hps-java project
cd online-recon

# Install the online recon run scripts to your work dir
mvn install -DskipTests -DskipCheckstyle -DassembleDirectory=/scratch

# Optionally add the script directory to the path.
export PATH=/scratch/bin:$PATH

...

The important ET connection parameters for this can be specified in an initial server config file like:

Code Block
languagebash
themeMidnight
titlemy.cfg
et.buffer=/tmp/ETBuffer
et.host=localhost
et.port=11111

...

You can launch the server now using a command like::

Code Block
languagebash
themeMidnight
hps-recon-server --host localhost --port 22222 -w $PWD/stations -c my.cfg &

...

Now you can connect to the running server using the online recon client:

Code Block
languagebash
themeMidnight
hps-recon-client --host localhost -c station.prop

...

You can create an initial file called station.prop which will usually have settings specific to the data format/year like detector name, run number, reconstruction steering file:

Code Block
languagebash
themeMidnight
lcsim.detector=HPS-PhysicsRun2016-Pass2
lcsim.run=7798
lcsim.steering=/org/hps/steering/recon/PhysicsRun2016OnlineRecon.lcsim

...

If you run the client without any command options, it will opens the interactive online reconstruction console which can be used to configure, create, start/stop and remove stations that run the HPS physics event reconstruction on data from the ET ring.

Code Block
languagebash
themeMidnight
hps-recon-client --host localhost

...

Type help into the console to show the documentation for the client command line interface:

Code Block
languagebash
themeMidnight
online>help


This is the output of the above command:

Code Block
languagebash
themeMidnight
GENERAL

    help - print general information
    help [cmd] - print information for specific command
    exit - quit the console

SETTINGS

    port [port] - set the server port
    host [host]- set the server hostname
    file [filename] - write server output to a file
    append [true|false] - true to append to output file or false to overwrite
    terminal - redirect server output back to the terminal

COMMANDS

    config - Set new server configuration properties
    create - Create a new station
    list - List station information in JSON format
    log - Tail log file of station (hit any key to stop tailing)
    remove - Remove a station that is inactive
    save - Save the current set of plots to a ROOT or AIDA file
    set - Set a configuration property
    shutdown - Shutdown the server
    start - Start a station that is inactive
    status - Show server and station status
    stop - Stop a station

...

If the server was started with a custom port or it is running with a particular hostname, this can be specified like:

Code Block
languagethemebashMidnight
online> port 12345
online> host myactualhostname

By default, output from the server read by the client is printed to the console, but it can be saved to a log file using commands such as:


Code Block
themeMidnight
online> file client.log
online> append true

...

Configuration of the online reconstruction stations can be set using:

Code Block
languagebash
# lcsim detector name for conditions
online>set lcsim.detector HPS-PhysicsRun2016-Pass2

# run number for conditions
online>set lcsim.run 7798

# lcsim steering resource
online>set lcsim.steering /org/hps/steering/recon/PhysicsRun2016OnlineRecon.lcsim

online>set lcsim.detector HPS-PhysicsRun2016-Pass2

...

A single station with the above configuration can be created using:

Code Block
languagethemebashMidnight
online>create 1

The argument is the number of stations you want the server to create, which can potentially scale reliably to around the number of cores on your machine.

...