Skip to content

Commit cf3c870

Browse files
sutaakaropenshift-merge-bot[bot]
authored andcommitted
Add property for MNIST dataset URL
1 parent 0581e43 commit cf3c870

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

support/environment.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ const (
4444

4545
// Hostname of the Kubernetes cluster
4646
ClusterHostname = "CLUSTER_HOSTNAME"
47+
48+
// URL for downloading MNIST dataset
49+
mnistDatasetURL = "MNIST_DATASET_URL"
4750
)
4851

4952
type ClusterType string
@@ -110,6 +113,10 @@ func GetClusterHostname(t Test) string {
110113
return hostname
111114
}
112115

116+
func GetMnistDatasetURL() string {
117+
return lookupEnvOrDefault(mnistDatasetURL, "http://yann.lecun.com/exdb/mnist/")
118+
}
119+
113120
func lookupEnvOrDefault(key, value string) string {
114121
if v, ok := os.LookupEnv(key); ok {
115122
return v

0 commit comments

Comments
 (0)