code: def populate_obj(self, obj=None, form=None):
          
          if not form:
              form = current_context.data.form
          if obj is None:
              obj = AttrDict()
          form.populate_obj(obj)
          return obj
docs: Populates an object with the form's data