Skip to content

Conversation

@Craigacp
Copy link
Member

Description

  • Updated the copyrights everywhere to include the correct year.
  • Shortened the setInvocationCount idiom.
  • Fixed a few bugs where the invocation count updated the wrong variable.
  • Added support for setting the invocation count to classifier chains.

Motivation

Tidying up a few things after the large merge.

- Updated the copyrights everywhere to include the correct year.
- Shortened the setInvocationCount idiom.
- Fixed a few bugs where the invocation count updated the wrong
  variable.
- Added support for setting the invocation count to classifier chains.
@Craigacp Craigacp added Oracle employee This PR is from an Oracle employee squash-commits Squash the commits when merging this PR labels Oct 28, 2021
Copy link
Member

@pogren pogren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this all looks straightforward.
more consistent naming of member variable trainInvocationCount (from invocationCount) and more succinct handling of it in respective setInvocationCount methods,

  • make setInvocationCount methods synchronized
  • SparseModel.train now has a default implementation for the method that takes an invocationCount
  • ClassifierChainTrainer has its own train method that takes invocationCount
  • misc. non-code edits - e.g. updated copyright statements, fixed typos

trainInvocationCounter++;

for (trainInvocationCounter = 0; trainInvocationCounter < invocationCount; trainInvocationCounter++){
SplittableRandom localRNG = rng.split();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this creates an "unused variable" compiler warning in my IDE. Do you care?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the localRNG? That's what I get in intellij, but it's intentional, it's the only way to advance the rng to the right state. I'm not sure if there is a suppress warning flag that will work across all IDEs, but if there is we can do that. We'll need to do something for the static analysis too, but that can be a problem for another day.

@Craigacp Craigacp merged commit 98ed939 into main Oct 28, 2021
@Craigacp Craigacp deleted the reproducibility-cleanups branch October 28, 2021 23:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Oracle employee This PR is from an Oracle employee squash-commits Squash the commits when merging this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants