Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add get pretrained method
Browse files Browse the repository at this point in the history
xzyaoi committed Jan 23, 2019
1 parent 70dc716 commit f006b1c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions cli/repository.go
Original file line number Diff line number Diff line change
@@ -195,3 +195,11 @@ func InitNewRepo(repoName string) {
bolierplateURL := "https://github.com/cvmodel/bolierplate.git"
CloneFromGit(bolierplateURL, repoName)
}

func GetPretrained(vendorName string, packageName string) []os.FileInfo {
config := readConfig()
localFolder := filepath.Join(config.Local.LocalFolder, vendorName, packageName)
localPretrainedFolder := filepath.Join(localFolder, "pretrained")
files, _ := ioutil.ReadDir(localPretrainedFolder)
return files
}

0 comments on commit f006b1c

Please sign in to comment.