Skip to content

AveragedPerceptron default iterations #5568

Closed

Description

When changing AveragedPerceptron's default number of iterations from 1 to 10 in #5258, we missed one.

The main interface continues to default to 1 iteration:
image

Previous issues:

Code location

Default is set here:

int numberOfIterations = Options.AveragedDefault.NumberOfIterations)

Which originates from:

internal class AveragedDefault : OnlineLinearOptions.OnlineDefault
{
public const float LearningRate = 1;
public const bool DecreaseLearningRate = false;
public const float L2Regularization = 0;
}

Which in-turn inherits its value from:

internal class OnlineDefault
{
public const int NumberOfIterations = 1;
}

Possible fix

We may want to make a new class within AveragedPerceptron to hold its overrides:

        internal class AveragedPerceptronDefault : AveragedDefault
        { 
            public const float NumberOfIterations = 10; 
        } 

/cc @michaelgsharp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

APIIssues pertaining the friendly APIP2Priority of the issue for triage purpose: Needs to be fixed at some point.bugSomething isn't workingclassificationBugs related classification tasksgood first issueGood for newcomersup-for-grabsA good issue to fix if you are trying to contribute to the project

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions