test-tube icon indicating copy to clipboard operation
test-tube copied to clipboard

Write basic tests for HyperOptArgumentParser

Open williamFalcon opened this issue 6 years ago • 2 comments

Initial tests should include:

  • Testing grid search generation
  • Testing random search generation
  • CPU parallelization
  • GPU parallelization
  • Releasing free GPUs and CPUs continuously so there isn't idle time on either

williamFalcon avatar Mar 22 '18 14:03 williamFalcon

I claimed to contribute to the "writing tests for log.py issue" a few weeks ago but just got started, and soon realize it might be helpful to understand argparse_hopt.py first as the Experiment class depends on it.

I have been trying to read the source code for the past two days and sort of understand the Experiment class now, but it would be great if you could kindly help offer some comments on the general purpose of the following classes in the argparse_hopt.py script... I'm not sure I entirely got what's happening in this file.

  • HyperOptArgumentParser class : why do you need this class to collect arguments (I guess), when you will parse the arguments in the log.py test with a parse method of the Experiment class later?
  • TTNamespace : what's the purpose of this class?
  • OptArg: is this class adjusting range of arguments?

Also, is hyperopt.py obsolete? It seems not being used anywhere or I might be missing something.

Thanks a lot!

yuqli avatar Nov 25 '18 20:11 yuqli

hyperopt.py is deprecated. TTNamespace is a weird python object for holding key-value pairs. OptArg has logic for manipulating a parameter HyperOptArgumentParser not sure what you're asking. This class is there for convenience to the user.

williamFalcon avatar Nov 27 '18 20:11 williamFalcon