Advanced Photon Source

An Office of Science National User Facility

Beamline Controls and Data Handling

Beamline Controls and Data Acquisition

Beamline controls operate through EPICS, with the standard MEDM graphical interface.

When needed, Python is used for scripting, based on the PyEpics implementation written by CARS. The beamline workstation has access to the Enthought and Anaconda Python distributions, which include many common Python packages, such as numpy, scipy, h5py, and others.

Data Formats

Time resolved data collected at the beamline are typically stored in a locally-defined binary data file. For distribution to users, these files are converted to HDF5, a widely used, hierarchical binary data format that can be accessed using tools in a wide variety of programming languages. Other formats can potentially be accommodated upon request; please contact beamline staff prior to your beamtime if a different format is needed.

Data collected at the beamline using the standard EPICS scan record (typically time-averaged data) are saved in an APS-specific binary format based on the Sun Microsystems XDR data format (described more fully here). Tools exist to visualize data while on-site. To make these data readable to outside users, the data can be converted either to ASCII text or to HDF5 binary format.

Moving Data from APS

To facilitate users returning their data to their home institution, the APS hosts an anonymous FTP server. Beamline staff will assist users in loading data onto the FTP server. To retrieve the data from the FTP server using a web browser:

  1. Navigate to .
  2. Click on the files you wish to download.

If you wish to use a terminal-based ftp client:

  1. Type ftp
  2. Use the user name anonymous
  3. Just hit Enter when asked for a password
  4. Type cd /pub/sector7/7bmb
  5. Type ls to see a listing of files on the server. Perform get operations to retrieve your files.
Data Retention Policy

While the beamline will store users' data temporarily, the ultimate responsibility for data retention lies with users. For time-averaged point detector data, the beamline will store users' data on APS servers for a minimum of two years. For time-resolved point detector data and all area detector data, the beamline will store user's data on APS servers for a minimum of one year.