Made script compatible with nvidia proprietary drivers.