AutoML doesn't use the default namespace of the project

Open
#3,062 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
csharp

Research direction

Start by tracing the AutoML class-generation step after Train/Evaluate and compare the generated namespace with the project's default namespace from project properties. Reproduce the listed workflow and inspect the generated classes. Done when they use the project's default namespace with dots and remain compatible with partial extensions.

Written by the indexing model from the issue text.

Description

System Information (please complete the following information):

  • Model Builder Version (available in Manage Extensions dialog): 17.19.2.2511501
  • Visual Studio Version : 17.14.9

Describe the bug

  • On which step of the process did you run into an issue: Train/Evaluate
  • Clear description of the problem:
    When generating classes, AutoML doens't use the default namespace of the project, but uses the name of the project and replace the dots with underscore

To Reproduce
Steps to reproduce the behavior:

  1. Create a new model, specify the data and train the model
  2. Click on next, it will generate the classes for the model and asks for a reload of the project
  3. The classes generated contain the wrong namespace

Expected behavior
Expected behaviour is to use the default namespace as defined in the project properties

Additional context
Not a blocking issue, just a cohesive thing. By default, in .Net, namespaces don't contain underscores, they contain dots. And if we want to extend the generated classes, we can create our own file to add additionnal properties/methods (thanks to the usage of partial classes) to our model. But the namespace in that file is the default namespace, whereas the generated classes by AutoML is not.

Dominant language
Dockerfile
Stars
285
Forks
66
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from dotnet/machinelearning-modelbuilder

All issues in dotnet/machinelearning-modelbuilder

Similar issues

More Machine Learning issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.