-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathRegressionPage.xaml
More file actions
166 lines (161 loc) · 7.38 KB
/
RegressionPage.xaml
File metadata and controls
166 lines (161 loc) · 7.38 KB
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
<Page x:Class="XamlBrewer.Uwp.MachineLearningSample.RegressionPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:oxy="using:OxyPlot.Windows"
xmlns:controls="using:Microsoft.UI.Xaml.Controls"
xmlns:lottie="using:Microsoft.Toolkit.Uwp.UI.Lottie"
mc:Ignorable="d"
Foreground="{StaticResource PageForegroundBrush}"
FontFamily="Segoe UI">
<Grid Background="Transparent"
Padding="48 34 0 0">
<Grid.RowDefinitions>
<RowDefinition Height="74" />
<RowDefinition Height="auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<TextBlock Foreground="{StaticResource PageTitleBrush}"
FontSize="48"
FontWeight="Light"
HorizontalAlignment="Left"
Margin="6 0 0 0"
TextLineBounds="TrimToCapHeight"
FontFamily="Segoe UI">
<Run Text="Regression"
FontFamily="Segoe UI" />
</TextBlock>
<Path Data="{StaticResource RegressionIcon}"
Fill="{StaticResource PageTitleBrush}"
VerticalAlignment="Top"
HorizontalAlignment="Right"
Height="48"
Width="48"
Margin="0 0 20 0"
Stretch="Uniform" />
<TextBlock Grid.Row="1"
FontSize="24"
TextWrapping="WrapWholeWords"
FontFamily="Segoe UI">Predicts NBA player salary by draft number, age, win shares, and box plus/minus.</TextBlock>
<!-- Main -->
<Grid Grid.Row="2"
ColumnSpacing="20"
RowSpacing="20"
Margin="0 40 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid Grid.Column="0"
ColumnSpacing="20"
RowSpacing="20"
VerticalAlignment="Top"
HorizontalAlignment="Stretch">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<TextBlock Grid.Row="0">Preparing the data</TextBlock>
<CheckBox x:Name="DatasetBox"
IsEnabled="False"
IsChecked="False"
Grid.Row="0"
Grid.Column="1" />
<TextBlock Grid.Row="1">Setting up the model</TextBlock>
<CheckBox x:Name="SettingUpBox"
IsEnabled="False"
IsChecked="False"
Grid.Row="1"
Grid.Column="1" />
<TextBlock Grid.Row="2">Training the model</TextBlock>
<CheckBox x:Name="TrainingBox"
IsEnabled="False"
IsChecked="False"
Grid.Row="2"
Grid.Column="1" />
<TextBlock Grid.Row="3">Evaluating the model</TextBlock>
<CheckBox x:Name="TestingBox"
IsEnabled="False"
IsChecked="False"
Grid.Row="3"
Grid.Column="1"
FontFamily="Segoe UI" />
<TextBlock Grid.Row="4">Plotting the result</TextBlock>
<CheckBox x:Name="PlottingBox"
IsEnabled="False"
IsChecked="False"
Grid.Row="4"
Grid.Column="1" />
<StackPanel Orientation="Horizontal"
Grid.Row="5">
<ComboBox x:Name="RegressionTrainersCombo"
SelectionChanged="RegressionTrainersCombo_SelectionChanged"
Header="Regression trainer" />
<Button x:Name="RestartButton" Margin="20"
Click="Page_Loaded">Restart</Button>
</StackPanel>
<controls:AnimatedVisualPlayer x:Name="BusyIndicator"
Visibility="Collapsed"
Height="180"
HorizontalAlignment="Left"
Grid.Row="5"
Grid.Column="0"
Margin="0 -180">
<lottie:LottieVisualSource x:Name="LottieJsonSource"
UriSource="ms-appx:///Assets/loading.json" />
</controls:AnimatedVisualPlayer>
<TextBlock Grid.Row="7">Predict</TextBlock>
<Slider x:Name="DraftSlider"
Maximum="35000000"
ValueChanged="Slider_ValueChanged"
Header="Draft Number"
HorizontalAlignment="Stretch"
Grid.Row="8" />
<Slider x:Name="WinsSlider"
Minimum="0"
Maximum="25"
ValueChanged="Slider_ValueChanged"
Header="Win Shares"
HorizontalAlignment="Stretch"
Grid.Row="9"
FontFamily="Segoe UI" />
<Slider x:Name="AgeSlider"
ValueChanged="Slider_ValueChanged"
Minimum="20"
Maximum="50"
Value="35"
Header="Age"
HorizontalAlignment="Stretch"
Grid.Row="8"
Grid.Column="1" />
<Slider x:Name="BoxSlider"
Minimum="-10"
Maximum="15"
ValueChanged="Slider_ValueChanged"
Header="Box Plus / Minus"
HorizontalAlignment="Stretch"
Grid.Row="9"
Grid.Column="1" />
</Grid>
<oxy:PlotView x:Name="Diagram"
Background="Transparent"
BorderThickness="0"
Margin="0 0 40 60"
Grid.Column="1" />
</Grid>
</Grid>
</Page>