Writing Thermistor python code