Added static_cast at dataset.cc IndexDataSet getpattern