User Tools

Site Tools


Remove used FLT peaks


The script timelessClearFLTGrains is part of the TIMEleSS tools. It takes a list of peaks (.flt file), compares it with a GrainSpotter output file (.log file), removes all peaks which have already been used and writes the leftover peaks in a new .flt file.

usage: timelessClearFLTGrains GSFile, oldFLT.flt newFLT.flt

Creates a new list of peaks in FLT format, removing peaks which have already
been assigned to grains by GrainSpotter This is part of the TIMEleSS project

positional arguments:
  gsfile                Name of GrainSpotter output file (required)
  oldFLT                FLT file used to generate g-vectors for indexing
  newFLT                Name of FLT file to be created (required)
optional arguments:
  -h, --help            show this help message and exit
  -v VERBOSE, --verbose VERBOSE
                        Write out more details about what it does. Default is
                        Default is False


Usage 1

One possibility which one may think of is to

  1. Remove the peaks of the phase of interest after a GrainSpotter run and then
  2. Repeat the GrainSpotter run and merge the output.

However, if you are also using the TIMEleSS tool for removing the G-vectors there is no point in doing this. G-vectors directly depend on the FLT grains so if you remove the used G-vectors it has the same effect. In practice this means: You won't get any new grains by doing both removing G-vectors and FLT peaks.

Usage 2

The other (more realistic) way to use this script is to remove the peaks from the other disturbing phases, such as pressure medium or pressure standard before dealing with the phase you actually want to investigate. Performing PeakSearch will give you not only the peaks of your phase of interest but also the peaks from anything else (e.g. Pt, KCl, diamond, …).

During the indexing process with GrainSpotter the software might get confused by these other peaks and misinterprets them as peaks from the phase of interest. There is a good chance that this produces you a whole lot of erroneous grains in the output later.

To avoid this, one can do a full analysis (see the general workflow) for the most abundant phase first (in most cases the pressure medium, like KCl or MgO). Then you can use this script to remove all peaks which belong to your most abundant phase. The outcome .flt file will be a lot smaller than before since the most abundant phase had probably also a very high quantity of peaks, even if it's highly symmetric. After that, you can repeat the indexing with your second-most abundant phase, remove the peaks again, continue to the third phase and so on.

The downside of this procedure is that you might also remove peaks that actually belong to your phase of interest - a misinterpretation the other way around so to say. In any case, check the GrainSpotter output carefully and be aware that there might be some grains missing.

processing/remove-used-flt.txt · Last modified: 2019/07/12 08:49 by matthias