<reponame>aitmlouk/fedn
from django import forms

from .models import Combiner, CombinerConfiguration


class CombinerForm(forms.ModelForm):
    class Meta:
        model = Combiner
        fields = ['name', 'status', 'timeout', 'timeout_lost','storage_type','storage_hostname', 'storage_port', 'storage_access_key', 'storage_secret_key',
                  'storage_bucket', 'storage_secure_mode','max_clients','model_id']


class CombinerConfigurationForm(forms.ModelForm):
    class Meta:
        model = CombinerConfiguration
        fields = ['combiner','algorithm','ml_framework','round_timeout', 'rounds', 'clients_required','clients_requested', 
                  'nr_local_epochs','local_batch_size','model_id', 'status']

from django import forms

from .models import Combiner, CombinerConfiguration


class CombinerForm(forms.ModelForm):
    class Meta:
        model = Combiner
        fields = ['name', 'status', 'timeout', 'timeout_lost','storage_type','storage_hostname', 'storage_port', 'storage_access_key', 'storage_secret_key',
                  'storage_bucket', 'storage_secure_mode','max_clients','model_id']


class CombinerConfigurationForm(forms.ModelForm):
    class Meta:
        model = CombinerConfiguration
        fields = ['combiner','algorithm','ml_framework','round_timeout', 'rounds', 'clients_required','clients_requested', 
                  'nr_local_epochs','local_batch_size','model_id', 'status']