def get_field_for_proxy(pref_proxy):
    field = {
        bool: models.BooleanField,
        int:  models.IntegerField,
        float: models.FloatField,
        datetime: models.DateTimeField,
    }.get(type(pref_proxy.default), models.TextField)()
    update_field_from_proxy(field, pref_proxy)
    return field
The diffusion timestep() function computes the timestep
dataset/ETHPy150Open idlesign/django-siteprefs/siteprefs/utils.py/get_field_for_proxy--crossover with--dataset/ETHPy150Open zingale/pyro2/diffusion/simulation.py/Simulation.compute_timestep