|Name||Last Update||Last Commit 6ce2d4c48ee – Add README||history|
|.gitignore||Loading commit data...|
|README.md||Loading commit data...|
|preprocessing.py||Loading commit data...|
Parallel traces preprocessing
This script applies preprocessing to power traces by combining pairs of samples.
The possible pairs of samples are taken inside a sliding window which slides over the trace.
The operation used to combine the samples can be chosen.
Thanks to Python
multiprocessing package, the trace is split into blocks that are processed in parallel.
Combining pairs of samples allows to launch a first-order CPA on a first-order masked implementation, which would otherwise require a second-order CPA.
# Download sources git clone email@example.com:brice.colombier/traces-preprocessing.git cd traces-preprocessing # Download and build dependencies: # On Windows pip install scikit-image # On Ubuntu sudo apt-get install python-skimage
The script is typically used in the following manner:
python preprocessing.py traces_masked.npy --op=multiplication --window_size=5 --min_dist=1 --dtype=float64 --ncores=4
The parameter is the file in which the traces are stored in
Options are detailed below.
--op: operation to compute on the pair of samples. Should belong to
--window_size: width of the sliding window
--min_dist: minimum distance between two samples in a pair
numpydata type for the samples of the processed trace
--ncores: number of cores to use for the parallel computation