blob: 0b63c5ac00308381c08064773122353a34fe0ade (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
|
<div id="container">
<div class="row">
<div class="col-sm">
<div class="row">
<mat-form-field class="example-full-width" appearance="fill">
<mat-label>Naziv</mat-label>
<input type="text" matInput [formControl]="nameFormControl">
<mat-error *ngIf="nameFormControl.hasError('name') && !nameFormControl.hasError('required')">
Unesite naziv
</mat-error>
<mat-error *ngIf="nameFormControl.hasError('required')">
Naziv je <strong>obavezan</strong>
</mat-error>
</mat-form-field>
</div>
<div class="row">
<mat-form-field appearance="fill">
<mat-label>Tip problema</mat-label>
<mat-select matNativeControl required [formControl]="selectTypeFormControl">
<mat-option
*ngFor="let option of Object.keys(ProblemType); let optionName of Object.values(ProblemType)"
[value]="option">
{{ optionName }}
</mat-option>
</mat-select>
<mat-error *ngIf="selectTypeFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
</div>
<div class="col-sm">
<div class="row">
<mat-form-field appearance="fill">
<mat-label>Optimizacija</mat-label>
<mat-select matNativeControl required [formControl]="selectOptFormControl">
<mat-option
*ngFor="let option of Object.keys(Optimizer); let optionName of Object.values(Optimizer)"
[value]="option">
{{ optionName }}
</mat-option>
</mat-select>
<mat-error *ngIf="selectOptFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
<div class="row">
<mat-form-field appearance="fill">
<mat-label>Funkcija troška</mat-label>
<mat-select matNativeControl required [formControl]="selectLFFormControl">
<mat-option
*ngFor="let option of Object.keys(lossFunction); let optionName of Object.values(lossFunction)"
[value]="option">
{{ optionName }}
</mat-option>
</mat-select>
<mat-error *ngIf="selectLFFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
</div>
<div class="col-sm">
<div class="row">
<mat-form-field appearance="fill">
<mat-label>Funkcija aktivacije izlaznog sloja</mat-label>
<mat-select matNativeControl required [formControl]="selectAFFormControl" name="outputLayerActivationFunction" [(ngModel)]="newModel.outputLayerActivationFunction">
<mat-option
*ngFor="let option of Object.keys(ActivationFunction); let optionName of Object.values(ActivationFunction)"
[value]="option">
{{ optionName }}
</mat-option>
</mat-select>
<mat-error *ngIf="selectAFFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
<div class="row">
<mat-form-field appearance="fill">
<mat-label>Funkcija troška</mat-label>
<mat-select matNativeControl required [formControl]="selectLFFormControl">
<mat-option
*ngFor="let option of Object.keys(lossFunction); let optionName of Object.values(lossFunction)"
[value]="option">
{{ optionName }}
</mat-option>
</mat-select>
<mat-error *ngIf="selectLFFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
</div>
<div class="col">
<div class="row">
<div class="col-7">Broj Epoha</div>
<mat-icon (click)="addEpoch()">add_circle</mat-icon>
<div class="col-1">{{newModel.epochs}}</div>
<mat-icon (click)="removeEpoch()">remove_circle</mat-icon>
</div>
<br>
<br>
<div class="row">
<div class="col-7">Broj Uzoraka Po Iteraciji</div>
<mat-icon (click)="addBatch()">add_circle</mat-icon>
<div class="col-1">{{newModel.batchSize}}</div>
<mat-icon (click)="removeBatch()">remove_circle</mat-icon>
</div>
</div>
</div><!--kraj unosa parametara-->
<hr>
<div class="m-5">
<app-graph [model]="newModel" [inputCols]="newModel.inputColNum"></app-graph>
<div class="row" id="rowhn">
<div class="col-3"></div>
<div class="col-2">Broj Skrivenih Slojeva</div>
<div class="col-1"><mat-icon (click)="addLayer()" (ngModelChange)="updateGraph()">add_circle</mat-icon></div>
<div class="col-1">{{newModel.hiddenLayers}}</div>
<div class="col-1"><mat-icon (click)="removeLayer()" (ngModelChange)="updateGraph()">remove_circle</mat-icon></div>
</div>
</div>
<hr>
<div class="row" style="max-width:60rem ;">
<div class="col text-center" *ngFor="let item of numSequence(newModel.hiddenLayers)" >
{{item}}
<div class="neuron">
<div style="text-align: center;">
<label >Skriveni sloj</label>
</div>
<div class="row" style="margin-bottom: -10px;">
<mat-form-field appearance="fill">
<mat-label>Aktivaciona funkcija</mat-label>
<mat-select matNativeControl required [formControl]="selectActivationFormControl">
<mat-option value="saab">Relu</mat-option>
<mat-option value="mercedes">Sigmoid</mat-option>
<mat-option value="audi">Softmax</mat-option>
</mat-select>
<mat-error *ngIf="selectActivationFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
<div class="row" >
<div class="col-6" style="font-size: 13px;" >Broj čvorova</div>
<mat-icon (click)="addNeuron()">add_circle</mat-icon>
<div class="col-1">{{newModel.hiddenLayerNeurons}}</div>
<mat-icon (click)="removeNeuron()">remove_circle</mat-icon>
</div>
<div class='row' style="margin-bottom: -7px;">
<mat-form-field appearance="fill">
<mat-label>Regularizacija</mat-label>
<mat-select matNativeControl required [formControl]="selectRegularisationFormControl">
<mat-option value="l1">L1</mat-option>
<mat-option value="l2">L2</mat-option>
</mat-select>
<mat-error *ngIf="selectRegularisationFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
<div class="row" style="margin-bottom: -7px;">
<mat-form-field appearance="fill">
<mat-label>Stopa regularizacije</mat-label>
<mat-select matNativeControl required [formControl]="selectRRateFormControl">
<mat-option value="saab">0.001</mat-option>
<mat-option value="mercedes">0.01</mat-option>
<mat-option value="audi">0.1</mat-option>
</mat-select>
<mat-error *ngIf="selectRRateFormControl.hasError('required')">
Obavezno polje
</mat-error>
</mat-form-field>
</div>
</div>
<br>
</div>
</div>
|