|
7 | 7 | xmlns:userControls="clr-namespace:OnnxStack.UI.UserControls"
|
8 | 8 | mc:Ignorable="d"
|
9 | 9 | Name="UI"
|
| 10 | + MinWidth="1200" |
| 11 | + MaxWidth="1200" |
10 | 12 | Icon="/Images/Icon.png"
|
11 | 13 | SizeToContent="WidthAndHeight"
|
12 | 14 | WindowStartupLocation="CenterOwner"
|
|
27 | 29 |
|
28 | 30 | <UniformGrid Columns="3" Margin="0,5,0,0">
|
29 | 31 |
|
30 |
| - <StackPanel Margin="0,0,4,0"> |
| 32 | + <StackPanel> |
31 | 33 | <TextBlock Text="Pipeline" />
|
32 | 34 | <ComboBox ItemsSource="{Binding Source={StaticResource DiffuserPipelineType}}" SelectedItem="{Binding UpdateModelSet.PipelineType}" />
|
33 | 35 | </StackPanel>
|
34 | 36 |
|
35 |
| - <StackPanel Margin="0,0,4,0"> |
| 37 | + <StackPanel Margin="4,0"> |
36 | 38 | <TextBlock Text="Model Type" />
|
37 | 39 | <ComboBox ItemsSource="{Binding Source={StaticResource ModelType}}" SelectedItem="{Binding UpdateModelSet.ModelType}" />
|
38 | 40 | </StackPanel>
|
39 |
| - <StackPanel Margin="0,0,4,0"> |
| 41 | + <StackPanel > |
40 | 42 | <TextBlock Text="Sample Size" />
|
41 | 43 | <TextBox Text="{Binding UpdateModelSet.SampleSize}" />
|
42 | 44 | </StackPanel>
|
|
53 | 55 | </GroupBox>
|
54 | 56 |
|
55 | 57 | <GroupBox Header="Performance" Margin="5,0" >
|
56 |
| - <UniformGrid Columns="2" Margin="5"> |
57 |
| - |
58 |
| - <StackPanel Margin="0,0,4,0"> |
59 |
| - <TextBlock Text="Execution Provider" /> |
60 |
| - <ComboBox ItemsSource="{Binding UISettings.SupportedExecutionProviders}" SelectedItem="{Binding UpdateModelSet.ExecutionProvider}" /> |
| 58 | + <StackPanel Margin="5"> |
| 59 | + <StackPanel Margin="0,0,4,0"> |
| 60 | + <TextBlock Text="Device" /> |
| 61 | + <userControls:DevicePickerControl |
| 62 | + UISettings="{Binding UISettings}" |
| 63 | + DeviceId="{Binding UpdateModelSet.DeviceId, Mode=TwoWay}" |
| 64 | + ExecutionProvider="{Binding UpdateModelSet.ExecutionProvider, Mode=TwoWay}" /> |
61 | 65 | </StackPanel>
|
62 |
| - <TextBlock /> |
63 |
| - <StackPanel Margin="0,0,4,0"> |
| 66 | + <StackPanel Margin="0,4,0,0"> |
64 | 67 | <TextBlock Text="Mode" />
|
65 | 68 | <ComboBox ItemsSource="{Binding Source={StaticResource ExecutionModeType}}" SelectedItem="{Binding UpdateModelSet.ExecutionMode}" />
|
66 | 69 | </StackPanel>
|
67 |
| - <StackPanel Margin="0,0,4,0"> |
68 |
| - <DockPanel> |
69 |
| - <TextBlock DockPanel.Dock="Left" Text="DeviceId" /> |
70 |
| - <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
71 |
| - </DockPanel> |
72 |
| - <TextBox Text="{Binding UpdateModelSet.DeviceId}" /> |
73 |
| - </StackPanel> |
74 |
| - <StackPanel Margin="0,0,4,0"> |
75 |
| - <DockPanel> |
76 |
| - <TextBlock DockPanel.Dock="Left" Text="InterOp Threads" /> |
77 |
| - <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
78 |
| - </DockPanel> |
79 |
| - <TextBox Text="{Binding UpdateModelSet.InterOpNumThreads}" /> |
80 |
| - </StackPanel> |
81 |
| - |
82 |
| - <StackPanel> |
83 |
| - <DockPanel> |
84 |
| - <TextBlock DockPanel.Dock="Left" Text="IntraOp Threads" /> |
85 |
| - <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
86 |
| - </DockPanel> |
87 |
| - <TextBox Text="{Binding UpdateModelSet.IntraOpNumThreads}" /> |
88 |
| - </StackPanel> |
89 |
| - </UniformGrid> |
| 70 | + <UniformGrid Columns="2" Margin="0,4,0,0"> |
| 71 | + <StackPanel Margin="0,0,2,0"> |
| 72 | + <DockPanel> |
| 73 | + <TextBlock DockPanel.Dock="Left" Text="InterOp Threads" /> |
| 74 | + <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
| 75 | + </DockPanel> |
| 76 | + <TextBox Text="{Binding UpdateModelSet.InterOpNumThreads}" /> |
| 77 | + </StackPanel> |
| 78 | + <StackPanel Margin="2,0,0,0"> |
| 79 | + <DockPanel> |
| 80 | + <TextBlock DockPanel.Dock="Left" Text="IntraOp Threads" /> |
| 81 | + <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
| 82 | + </DockPanel> |
| 83 | + <TextBox Text="{Binding UpdateModelSet.IntraOpNumThreads}" /> |
| 84 | + </StackPanel> |
| 85 | + </UniformGrid> |
| 86 | + </StackPanel> |
90 | 87 | </GroupBox>
|
91 | 88 |
|
92 | 89 | <GroupBox Header="Advanced Settings" >
|
|
148 | 145 | </DockPanel>
|
149 | 146 |
|
150 | 147 | <!--Override Defaults-->
|
151 |
| - <UniformGrid Grid.Column="0" Columns="5" Visibility="{Binding IsOverrideEnabled, Converter={StaticResource BooleanToVisibilityConverter}}" Margin="0,5,0,10"> |
| 148 | + <UniformGrid Grid.Column="0" Columns="4" Visibility="{Binding IsOverrideEnabled, Converter={StaticResource BooleanToVisibilityConverter}}" Margin="0,5,0,10"> |
152 | 149 | <StackPanel Margin="0,0,4,0">
|
153 |
| - <TextBlock Text="Provider" /> |
154 |
| - <ComboBox ItemsSource="{Binding UISettings.SupportedExecutionProviders, ElementName=UI}" SelectedItem="{Binding ExecutionProvider}" /> |
| 150 | + <TextBlock Text="Device" /> |
| 151 | + <userControls:DevicePickerControl |
| 152 | + UISettings="{Binding UISettings, ElementName=UI}" |
| 153 | + DeviceId="{Binding DeviceId, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" |
| 154 | + ExecutionProvider="{Binding ExecutionProvider, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" /> |
155 | 155 | </StackPanel>
|
| 156 | + |
156 | 157 | <StackPanel Margin="0,0,4,0">
|
157 | 158 | <TextBlock Text="Mode" />
|
158 | 159 | <ComboBox ItemsSource="{Binding Source={StaticResource ExecutionModeType}}" SelectedItem="{Binding ExecutionMode}" />
|
159 | 160 | </StackPanel>
|
160 |
| - <StackPanel Margin="0,0,4,0"> |
161 |
| - <DockPanel> |
162 |
| - <TextBlock DockPanel.Dock="Left" Text="DeviceId" /> |
163 |
| - <TextBlock Text="(0=auto)" FontSize="9" FontStyle="Italic" Margin="6,0,6,0" Opacity="0.5" HorizontalAlignment="Right" VerticalAlignment="Center"/> |
164 |
| - </DockPanel> |
165 |
| - <TextBox Text="{Binding DeviceId, TargetNullValue=''}" /> |
166 |
| - </StackPanel> |
| 161 | + |
167 | 162 | <StackPanel Margin="0,0,4,0">
|
168 | 163 | <DockPanel>
|
169 | 164 | <TextBlock DockPanel.Dock="Left" Text="InterOp Threads" />
|
|
0 commit comments