Because of external pull-up resistor, the output of DS18B20 may be 0V or 3.3V; as a result, your experiment my produce 0 or 1023.
Because of external pull-up resistor, the output of DS18B20 may be 0V or 3.3V; as a result, your experiment my produce 0 or 1023.