No description, website, or topics provided.
C++ Shell C Perl Makefile
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
backup Initial commit Aug 12, 2015
gemm_BM Initial commit Aug 12, 2015
results Initial commit Aug 12, 2015
Makefile Initial commit Aug 12, 2015
README.md Update README.md Jun 2, 2017
batch_mkdir.sh Initial commit Aug 12, 2015
decide_mc.cpp Initial commit Aug 12, 2015
decide_mc.o Initial commit Aug 12, 2015
defines.h Initial commit Aug 12, 2015
driver-gen.cpp Initial commit Aug 12, 2015
driver-gen.o Initial commit Aug 12, 2015
driver-ttm.cpp Initial commit Aug 12, 2015
driver-ttm.o Initial commit Aug 12, 2015
driver.h Initial commit Aug 12, 2015
gen_ttm Initial commit Aug 12, 2015
gen_ttm.cpp Initial commit Aug 12, 2015
gen_ttm.o Initial commit Aug 12, 2015
hpcdefs.h Initial commit Aug 12, 2015
out.txt Initial commit Aug 12, 2015
run_InTensLi.sh Initial commit Aug 12, 2015
run_batch_mkl.sh Initial commit Aug 12, 2015
run_one.sh
timer.cpp Initial commit Aug 12, 2015
timer.h Initial commit Aug 12, 2015
timer.o Initial commit Aug 12, 2015
ttm Initial commit Aug 12, 2015
ttm.cpp Initial commit Aug 12, 2015
ttm.o Initial commit Aug 12, 2015
util.cpp Initial commit Aug 12, 2015
util.o Initial commit Aug 12, 2015

README.md

About InTensLi (Input-adaptive and in-place dense tensor-times-matrix multiply)

Overview

To compute a mode-n product: Y=X * U, where X and Y are dense tensors, U is a dense matrix. * represents mode-n product.
There are two stages: first is to generate ttm code according to input tensor and other parameters (gen_ttm); second is to use generated "ttm.cpp" to run ttm code and test its performance.
The tests use random generated dense tensors, users can specify the tensor dimension and maximum and minimum dimension sizes.

How to run?

Refer to script file "run_InTensLi.sh" to run InTensLi as a whole.
The input parameters for executable file "gen_ttm" and "ttm" are the same.
./gen_ttm (or ./ttm)

  • -dim=[Dimension]
  • -maxdimsize=[maximum dimension size]
  • -mindimsize=[minimum dimension size]
    Other dimension sizes are generated by evenly distributed betwee the max and min.
  • -mode=[mode-n product, the mode to be multiplied]
  • -R=[the low-rank value, size of dimension n of the generated tensor Y]
  • -strategy=[1, forward-strategy; 2: backward-strategy]
  • -degree=[number of dimensions used to build inner-most MM kernel]
  • -OMPNT=[number of threads used in for loops]
  • -MKLNT=[number of threads used in MM kernel]
    Parameters "degree", "OMPNT", and "MKLNT" can be specified by users, although InTensLi itself decides reasonable values for them.

Code structure

  • defines.h: use this file to define macros.
  • driver-gen.cpp: main file for the first stage.
  • gen_ttm.cpp: generate "ttm.cpp" for a particular input tensor.
  • decide_mc.cpp:
    1. function decide_component_mode: split tensor dimensions into two parts, modes used in inner matrix multiplication kernel (M_C) and modes used as loops (M_L).
    2. function decide_paras: determine "degree" value and threads used in for loops ("omp_nt"), in MM kernel ("mkl_nt").
  • driver-ttm.cpp: main file to the second stage.
  • util.cpp: auxiliary functions.
  • timer.cpp: timing functions.
  • hpcdefs.h: used in timer.cpp.

Note: Code is not pretty now. Welcome any feedback to improve it!
Contact: Jiajia Li (jiajiali@gatech.edu)