Documentation
¶
Index ¶
- Constants
- func AddContentIPFS(content []byte) (string, error)
- func ComputeAlignmentScore(modelID string, csMatrix [][]float64) []float64
- func ComputeCS(a []float64, b []float64) float64
- func ComputeCSMatrix(modelID string) ([][]float64, error)
- func ComputeClassCS(a [][]float64, b [][]float64) float64
- func ComputeGradients(modelID string) (map[string][][]float64, error)
- func ComputePhi(algnScores []float64) []float64
- func ComputeTrust(modelID string, algnScore []float64) (map[string]float32, error)
- func ConvertScoreToNumpy(modelID string, score interface{}, purpose uint32) (string, error)
- func EvaluatePardoning(modelID string, algnScore []float64, csMatrix [][]float64) ([][]float64, []float64, error)
- func GetAlignmentFromNumpy(path string) ([]float64, error)
- func GetContentIPFS(path string) ([]byte, error)
- func GetLatestGradients(modelID string) (map[string][][]float64, error)
- func GetLatestRoundTimestamp(modelID string) (uint32, error)
- func GetLatestTrustScores(modelID string) (map[string]float32, error)
- func GetLatestWeights(modelID string, clientPubkey string) ([][]float64, [][]float64, error)
- func GetPhiFromNumpy(path string) ([]float64, error)
- func GetScoreByBlockID(blockID string) (scpb.Score, error)
- func GetScorePath(modelID string, scoreType string) (*scpb.Score, error)
- func GetSimilarityFromNumpy(path string) ([][]float64, error)
- func GetTrustFromNumpy(path string) ([]float64, error)
- func GetVote(blockID string) (vpb.Vote, error)
- func GetWeightsFromNumpy(path string) ([][]float64, error)
- func Initialize(modelID string, x int, y int) error
- func PublishScore(modelID string, content interface{}, purpose uint32) error
- func RetrieveVote(voteID string) (*vpb.Vote, error)
- func Run(modelID string) error
- func SaveVote(vote vpb.Vote) error
- func SendVote(votePayload vpb.Vote) (string, error)
- func StoreGradientsIPFS(gradients map[string][][]float64) (string, error)
- func StoreLatestRoundTimestamp(modelID string, timestamp uint32) error
- func StoreScoreLocally(modelID string, score scpb.Score) error
- func StoreScoreOnTangle(score scpb.Score) (string, error)
- type Block
- type Gradients
- type Payload
Constants ¶
View Source
const ( INF = 1000 THRESHOLD = 0.1 DECAY_RATE = 0.0001 DELTA = 0.01 ALPHA = 0.5 K = 10 TRUST_PURPOSE_ID = 21 SIMILARITY_PURPOSE_ID = 22 ALIGNMENT_PURPOSE_ID = 23 GRADIENTS_PURPOSE_ID = 24 PHI_PURPOSE_ID = 25 )
View Source
const ( LEVELDB_ENDPOINT = "./../ldb" VOTE_PURPOSE_ID = 18 )
Variables ¶
This section is empty.
Functions ¶
func AddContentIPFS ¶
func ComputeAlignmentScore ¶
func ComputeCSMatrix ¶
func ComputeClassCS ¶
func ComputePhi ¶
func ComputeTrust ¶
func ConvertScoreToNumpy ¶
func EvaluatePardoning ¶
func GetAlignmentFromNumpy ¶
func GetContentIPFS ¶
func GetLatestRoundTimestamp ¶
func GetLatestWeights ¶
func GetPhiFromNumpy ¶
func GetSimilarityFromNumpy ¶
func GetTrustFromNumpy ¶
func GetWeightsFromNumpy ¶
func PublishScore ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.