spine.ana.template
Analysis module template.
Use this template as a basis to build your own analysis script. An analysis script takes the output of the reconstruction and the post-processors and performs basic selection cuts and stores the output to a CSV file.
Classes
|
Description of what the analysis script is supposed to be doing. |
- class spine.ana.template.TemplateAna(arg0, arg1, obj_type, run_mode, append_file, overwrite_file, output_prefix)[source]
Description of what the analysis script is supposed to be doing.
- Attributes:
dep_modesDictionary which makes the correspondance between the name of a true object deposition attribute with the underlying deposition array it points to.
keysDictionary of (key, necessity) pairs which determine which data keys are needed/optional for the post-processor to run.
point_modesDictionary which makes the correspondance between the name of a true object point attribute with the underlying point tensor it points to.
Methods
__call__(data[, entry])Runs the analysis script on one entry.
append(name, **kwargs)Apppend a CSV log file with a set of values.
close_writers()Close all CSV writers and flush any remaining data.
flush_writers()Flush all CSV writer buffers without closing the files.
get_base_dict(data)Builds the entry information dictionary.
get_index(obj)Get a certain pre-defined index attribute of an object.
get_points(obj)Get a certain pre-defined point attribute of an object.
initialize_writer(name)Adds a CSV writer to the list of writers for this script.
process(data)Pass data products corresponding to one entry through the analysis.
update_keys(update_dict)Update the underlying set of keys and their necessity in place.
- name = 'template'