changed //std::cout to LogDebug