Print

Print


Hi all,
  Hoping someone can help me with this one. I'm finding passing data
between classes troublesome. What I'm trying to do is have an ERC that has
indices that map to a table cell built up by Problem.setup from reading the
training data.
  The issue is that I want the max indices to be dynamic and determined
during the reading of the training data file during Problem setup. I can't,
however, figure out how to get that info from the Problem class to the ERC
class so it can mutate without running into out of bounds issues.
  I've tried setting some custom parameters during Problem.setup but that
class gets instantiated after my ERC class so my ERC class can't find said
parameters cause they haven't been set yet.
  The only thing I can think of, which I don't really want to do, is to
subclass SimpleEvolutionState and put in some fields and methods that
Problem.setup can call to set, and MyERC can call to get.
  This all feels very clunky and I feel like there's got to be a better way.

Any help is appreciated.

Thanks,

-Mark