<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://viper.lbl.gov:8080/cctbx.xfel/index.php?action=history&amp;feed=atom&amp;title=Data_viewer</id>
	<title>Data viewer - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://viper.lbl.gov:8080/cctbx.xfel/index.php?action=history&amp;feed=atom&amp;title=Data_viewer"/>
	<link rel="alternate" type="text/html" href="http://viper.lbl.gov:8080/cctbx.xfel/index.php?title=Data_viewer&amp;action=history"/>
	<updated>2026-06-24T09:07:44Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.15</generator>
	<entry>
		<id>http://viper.lbl.gov:8080/cctbx.xfel/index.php?title=Data_viewer&amp;diff=1292&amp;oldid=prev</id>
		<title>Aaron at 16:16, 19 October 2016</title>
		<link rel="alternate" type="text/html" href="http://viper.lbl.gov:8080/cctbx.xfel/index.php?title=Data_viewer&amp;diff=1292&amp;oldid=prev"/>
		<updated>2016-10-19T16:16:10Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;The command &amp;quot;cxi.pyana&amp;quot; can be configured to display the diffraction images streamed from an XTC file.&lt;br /&gt;
&lt;br /&gt;
== Configuring the viewer ==&lt;br /&gt;
Add to the mod_view section of your pyana config file as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[pyana]&lt;br /&gt;
modules = my_ana_pkg.mod_view&lt;br /&gt;
num-cpu = 1&lt;br /&gt;
&lt;br /&gt;
[my_ana_pkg.mod_view]&lt;br /&gt;
address     = CxiDs1-0|Cspad-0&lt;br /&gt;
calib_dir   = /reg/g/cctbx/sources/cctbx_project/xfel/metrology/CSPad/run4/CxiDs1.0_Cspad.0&lt;br /&gt;
dark_path       = /reg/d/psdm/cxi/cxib9713/res/darks/r0001-Ds1-avg.pickle&lt;br /&gt;
dark_stddev     = /reg/d/psdm/cxi/cxib9713/res/darks/r0001-Ds1-stddev.pickle&lt;br /&gt;
detz_offset = 555&lt;br /&gt;
&lt;br /&gt;
# Suitable values depend on the repetition rate of the instrument.&lt;br /&gt;
n_update    = 120&lt;br /&gt;
n_collate   = 60&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The command is run as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cxi.pyana -c myconfig_file.cfg /path/to/xtc/streams/e346-r0007-s0[0-4]-c00.xtc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The command will marshal together all events from streams 0-4 in run 7 of experiment 346.  Those events with the CXI imaging detector with the given &amp;lt;code&amp;gt;address&amp;lt;/code&amp;gt; will be sent to the &amp;lt;code&amp;gt;mod_view&amp;lt;/code&amp;gt; module that displays images in a GUI.  Dark subtraction is done with the files &amp;lt;code&amp;gt;dark_path&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;dark_stddev&amp;lt;/code&amp;gt; that are described on the [[Preparatory steps]] wiki page.&lt;br /&gt;
Important parameters are:&lt;br /&gt;
* &amp;lt;code&amp;gt;n_update&amp;lt;/code&amp;gt;: GUI will only display every Nth event (every 120th image, in this example).&lt;br /&gt;
* &amp;lt;code&amp;gt;n_collate&amp;lt;/code&amp;gt;: GUI will display an average image over the last N events (last 60 events, in this example).&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Critical step:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Please press the Run/Pause (green) button in the GUI to make the action start.&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;</summary>
		<author><name>Aaron</name></author>
	</entry>
</feed>