resolved bug in localisation with histogram