tuner.py : Prevent to update the threshold value if the data list is empty