'Returns the number of forms that are required in this FormSet.'

def initial_form_count(self):

    if (not (self.data or self.files)):
        return len(self.get_queryset())
    return super(BaseModelFormSet, self).initial_form_count()
