Skip to content

Text-Classification: Invocation exception when cross-validation #2718

Closed
dotnet/machinelearning
#6768
@Symbai

Description

@Symbai

System Information (please complete the following information):

  • Model Builder Version (available in Manage Extensions dialog):
    image

  • Visual Studio Version 17.7.0 Preview 2.0

Describe the bug
Every time I reopen the project (also happens when creating a new project) and I select a DIFFERENT a csv file (small or big one doesnt matter) and I try to pick a label column VS crashes completely. But the "Preview data" shows my new CSV content. Only occurs when a CSV was selected and model trained etc and I select a different a csv file and try to pick the first column. Selecting a csv file for the first time always works.

My mbconfig file: #2716 (comment)

To Reproduce

  1. Create a new text classification model based on a CSV file, train this model
  2. Go to Data tab, pick a new CSV file
  3. Wait until VS shows the content
  4. Open the combobox of the first column (label).
  5. VS crashes. I can reproduce this over and over again

Expected behavior
No crash?

Additional context

Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Exception
   at Microsoft.ML.ModelBuilder.Configuration.Extension.TrainingConfigurationExtension.SetColumnPurpose(Microsoft.ML.ModelBuilder.Configuration.ITrainingConfiguration, System.String, Microsoft.ML.ModelBuilder.Configuration.ColumnPurposeType)
   at Microsoft.ML.ModelBuilder.Configuration.Extension.TrainingConfigurationExtension.SetLabelName(Microsoft.ML.ModelBuilder.Configuration.ITrainingConfiguration, System.String)
   at Microsoft.ML.ModelBuilder.ToolWindows.LabelColumnComponentControl.PredictColumnSelectionCombo_SelectionChanged(System.Object, System.Windows.Controls.SelectionChangedEventArgs)
   at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject, System.Windows.RoutedEventArgs)
   at System.Windows.Controls.ComboBox.OnSelectionChanged(System.Windows.Controls.SelectionChangedEventArgs)
   at System.Windows.Controls.Primitives.Selector+SelectionChanger.End()
   at System.Windows.Controls.Primitives.Selector+SelectionChanger.SelectJustThisItem(ItemInfo, Boolean)
   at System.Windows.Controls.ComboBox.NotifyComboBoxItemMouseUp(System.Windows.Controls.ComboBoxItem)
   at System.Windows.Controls.ComboBoxItem.OnMouseLeftButtonUp(System.Windows.Input.MouseButtonEventArgs)
   at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.UIElement.ReRaiseEventAs(System.Windows.DependencyObject, System.Windows.RoutedEventArgs, System.Windows.RoutedEvent)
   at System.Windows.UIElement.OnMouseUpThunk(System.Object, System.Windows.Input.MouseButtonEventArgs)
   at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject, System.Windows.RoutedEventArgs)
   at System.Windows.UIElement.RaiseTrustedEvent(System.Windows.RoutedEventArgs)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputManager.ProcessInput(System.Windows.Input.InputEventArgs)
   at System.Windows.Input.InputProviderSite.ReportInput(System.Windows.Input.InputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr, System.Windows.Input.InputMode, Int32, System.Windows.Input.RawMouseActions, Int32, Int32, Int32)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr, MS.Internal.Interop.WindowMessage, IntPtr, IntPtr, Boolean ByRef)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)

Metadata

Metadata

Labels

BugSomething isn't workingPriority:0Work that we can't release without

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions