Documentation ¶
Index ¶
- Constants
- Variables
- func AsSha256(o interface{}) string
- func Create(fileName string) (*os.File, error)
- func FileExists(filename string) bool
- func GetAllProtocol() (protocols []string)
- func RemoveDir(dir string) error
- type GCSObjectDownloader
- func (g *GCSObjectDownloader) Download(client stiface.Client, it stiface.ObjectIterator) error
- func (g *GCSObjectDownloader) DownloadFile(client stiface.Client, attrs *gstorage.ObjectAttrs, file *os.File) error
- func (g *GCSObjectDownloader) GetObjectIterator(client stiface.Client) (stiface.ObjectIterator, error)
- func (g *GCSObjectDownloader) WriteToFile(data []byte, attrs *gstorage.ObjectAttrs, file *os.File) error
- type GCSProvider
- type HTTPSDownloader
- type HTTPSProvider
- type Protocol
- type Provider
- type S3ObjectDownloader
- type S3Provider
Constants ¶
View Source
const (
HEADER_SUFFIX = "-headers"
)
Variables ¶
Functions ¶
func FileExists ¶
func GetAllProtocol ¶ added in v0.5.1
func GetAllProtocol() (protocols []string)
Types ¶
type GCSObjectDownloader ¶
type GCSObjectDownloader struct { Context context.Context StorageUri string ModelDir string ModelName string Bucket string Item string }
func (*GCSObjectDownloader) Download ¶
func (g *GCSObjectDownloader) Download(client stiface.Client, it stiface.ObjectIterator) error
func (*GCSObjectDownloader) DownloadFile ¶
func (g *GCSObjectDownloader) DownloadFile(client stiface.Client, attrs *gstorage.ObjectAttrs, file *os.File) error
func (*GCSObjectDownloader) GetObjectIterator ¶
func (g *GCSObjectDownloader) GetObjectIterator(client stiface.Client) (stiface.ObjectIterator, error)
func (*GCSObjectDownloader) WriteToFile ¶
func (g *GCSObjectDownloader) WriteToFile(data []byte, attrs *gstorage.ObjectAttrs, file *os.File) error
type GCSProvider ¶
func (*GCSProvider) DownloadModel ¶
func (p *GCSProvider) DownloadModel(modelDir string, modelName string, storageUri string) error
type HTTPSDownloader ¶ added in v0.6.0
type HTTPSProvider ¶ added in v0.6.0
func (*HTTPSProvider) DownloadModel ¶ added in v0.6.0
func (m *HTTPSProvider) DownloadModel(modelDir string, modelName string, storageUri string) error
type Provider ¶
type S3ObjectDownloader ¶
type S3ObjectDownloader struct { StorageUri string ModelDir string ModelName string Bucket string Prefix string // contains filtered or unexported fields }
func (*S3ObjectDownloader) Download ¶
func (s *S3ObjectDownloader) Download(objects []s3manager.BatchDownloadObject) error
func (*S3ObjectDownloader) GetAllObjects ¶
func (s *S3ObjectDownloader) GetAllObjects(s3Svc s3iface.S3API) ([]s3manager.BatchDownloadObject, error)
type S3Provider ¶
type S3Provider struct { Client s3iface.S3API Downloader s3manageriface.DownloadWithIterator }
func (*S3Provider) DownloadModel ¶
func (m *S3Provider) DownloadModel(modelDir string, modelName string, storageUri string) error
Click to show internal directories.
Click to hide internal directories.