Tuesday, January 20, 2009

MSF Excel Plugin timings

It looks like the MS Solver Foundation Excel Plugin is somewhat slow for importing larger data sets (we observed this in this note). Here are a few timings that confirm this:


CellsMSF Excel PluginGAMS gdxxrw
n=1000.71.2
n=10002.71.3
n=1000023.01.4


Timings are in seconds. We see the MSF timings increase quickly, while the GAMS timings are still dominated by the fixed cost of launching Excel.

MSF Model:

Binding: P<=="Sheet1!$B$2:$CW$101"
Model[
Parameters[Sets,I,J],
Parameters[Reals,P[I,J]],
Decisions[Reals,d],
Constraints[d==0]
]

GAMS Model:

$call gdxxrw i=data.xlsx par=p rng=A1:CW101
parameter p(*,*);
$gdxin data
$load p

scalar n;
n=card(p);
display n;


The MSF code contains a large parameter that is read through data binding, together with a minimal (one variable, one constraint) model. The GAMS code calls GDXXRW to read the spreadsheet and then the intermediate GDX file is read again by GAMS. We display the cardinality of p as a check we read all numbers.