Example test
Example showing how the test suite can be used to add tests for a new algorithm.
TestExampleAlgo #
Bases: LearningAlgorithmTests[ExampleAlgorithm]
Tests for the ExampleAlgorithm
.
This runs all the tests included in the base class, with the given parametrizations:
algorithm_config
will take the value"example"
- This is because there is an
example.yaml
config file whose_target_
is theExampleAlgorithm
.
- This is because there is an
datamodule_config
will take these values:['cifar10', 'fashion_mnist', 'imagenet', 'imagenet32', 'inaturalist', 'mnist']
- These are all the configs whose target is an
ImageClassificationDataModule
.
- These are all the configs whose target is an
- Similarly,
network_config
will be parametrized by the names of all configs which produce an nn.Module.
Take a look at the LearningAlgorithmTests class if you want to see the actual test code.