Documentation ¶
Index ¶
- Constants
- type MLModel
- type Repository
- func (r *Repository) ChangeFeaturesCount(ctx context.Context, userID, modelType string, featuresCount int) error
- func (r *Repository) CreateModel(ctx context.Context, userID, modelType string) error
- func (r *Repository) GetModelByUserID(ctx context.Context, userID, modelType string) (*MLModel, error)
- func (r *Repository) GetModelsByUserID(ctx context.Context, userID string) ([]MLModel, error)
- func (r *Repository) SetFeaturesCountUsed(ctx context.Context, userID, modelType string, featuresCount int) error
- func (r *Repository) SetModelS3Key(ctx context.Context, s3Key, modelType, userID string) error
- func (r *Repository) SetModelStatus(ctx context.Context, status, modelType string, userID string) error
- func (r *Repository) ViewNotFineTunedFaceModels(ctx context.Context, modelType string, tuneThreshold uint64) ([]MLModel, error)
- func (r *Repository) ViewNotLearnedModels(ctx context.Context, modelType string, trainThreshold uint64) ([]MLModel, error)
Constants ¶
View Source
const ( StatusNotTrain = "not_train" StatusInTrainProcess = "in_train_process" StatusInTuneProcess = "in_tune_process" StatusTrained = "train" )
View Source
const (
FaceModel = "face_model"
)
View Source
const (
ModelsTable = "models"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(db postgresql.DB) *Repository
func (*Repository) ChangeFeaturesCount ¶
func (*Repository) CreateModel ¶
func (r *Repository) CreateModel(ctx context.Context, userID, modelType string) error
func (*Repository) GetModelByUserID ¶
func (*Repository) GetModelsByUserID ¶
func (*Repository) SetFeaturesCountUsed ¶
func (*Repository) SetModelS3Key ¶
func (r *Repository) SetModelS3Key(ctx context.Context, s3Key, modelType, userID string) error
func (*Repository) SetModelStatus ¶
func (*Repository) ViewNotFineTunedFaceModels ¶
func (*Repository) ViewNotLearnedModels ¶
Click to show internal directories.
Click to hide internal directories.