Base:
method
SampleFromFeatureSpace
Microsoft.ML.SearchSpace.Option.OptionBase.SampleFromFeatureSpace(System.Double[])
13 references to SampleFromFeatureSpace
Microsoft.ML.SearchSpace (1)
Converter\ChoiceOptionConverter.cs (1)
40Default = value.SampleFromFeatureSpace(value.Default),
Microsoft.ML.SearchSpace.Tests (12)
ChoiceOptionTest.cs (12)
22option.SampleFromFeatureSpace(new[] { 0.0 }).AsType<string>().Should().Be("a"); 23option.SampleFromFeatureSpace(new[] { 0.33 }).AsType<string>().Should().Be("a"); 24option.SampleFromFeatureSpace(new[] { 0.34 }).AsType<string>().Should().Be("b"); 25option.SampleFromFeatureSpace(new[] { 0.66 }).AsType<string>().Should().Be("b"); 26option.SampleFromFeatureSpace(new[] { 0.67 }).AsType<string>().Should().Be("c"); 27option.SampleFromFeatureSpace(new[] { 0.97 }).AsType<string>().Should().Be("c"); 28option.SampleFromFeatureSpace(new[] { 0.999999999 }).AsType<string>().Should().Be("c"); 29option.SampleFromFeatureSpace(new[] { 1.0 }).AsType<string>().Should().Be("c"); 36option.SampleFromFeatureSpace(new[] { 0.0 }).AsType<string>().Should().Be("a"); 37option.SampleFromFeatureSpace(new[] { 0.99 }).AsType<string>().Should().Be("a"); 49var parameter = option.SampleFromFeatureSpace(new[] { 0.5 }); 60option.SampleFromFeatureSpace(new double[0]).AsType<string>().Should().Be("b");