Versions in this module Expand all Collapse all v1 v1.0.0 Oct 16, 2021 Changes in this version + const DefaultSharpenSigma + const InterMinAboveThreshold + const InterThreashold + const MinSubsetCnt + const MinSubsetScore + const NMS_Threshold + const ThresholdHumanScore + const ThresholdPartConfidence + const TotalBodyParts + var CocoColors = [][3]uint8 + var CocoPairs = [][2]CocoPart + var CocoPairsNetwork = [][2]CocoPart + var CocoPairsRender = CocoPairs[0 : len(CocoPairs)-2] + var CoordParts = []CocoPart + var CoordPartsMap = map[CocoPart]struct + var PartPairs = []PartPair + var ZP = Point + var ZR = Rect(0, 0, 0, 0) + var ZS = ASize(0, 0) + func BodyPartID(humanID int, part CocoPart) string + func ColorFromHex(hexColor string) color.RGBA + func DrawHumans(img image.Image, humans []Human, strokeWidth float64) image.Image + func RoundInt(v float64) int + type BodyPart struct + Part CocoPart + Point Point + Score float32 + func NewBodyPart(part CocoPart, point Point, score float32) BodyPart + func (b BodyPart) String() string + type BodyPartPair struct + Parts [2]CocoPart + Points [2]Point + Score float64 + type CocoPart int + const CocoPartBackground + const CocoPartLAnkle + const CocoPartLEar + const CocoPartLElbow + const CocoPartLEye + const CocoPartLHip + const CocoPartLKnee + const CocoPartLShoulder + const CocoPartLWrist + const CocoPartNeck + const CocoPartNose + const CocoPartRAnkle + const CocoPartREar + const CocoPartRElbow + const CocoPartREye + const CocoPartRHip + const CocoPartRKnee + const CocoPartRShoulder + const CocoPartRWrist + type Connection struct + Coords [2]image.Point + Idx [2]int + NormPadding Size + Parts [2]CocoPart + Score float32 + Scores [2]float32 + UPartIdx map[string]struct{} + func (c Connection) GetUPartIdx() map[string]struct{} + func (c Connection) ToBodyParts(parts *[2]BodyPart, rows float64, cols float64) + type Human struct + Parts map[CocoPart]BodyPart + Score float32 + func NewHuman() *Human + func (h *Human) Reset() + func (h Human) GetFaceBox(imgW float64, imgH float64, mode int) Rectangle + func (h Human) GetMaxScore() float32 + func (h Human) GetUpperBodyBox(imgW float64, imgH float64) Rectangle + func (h Human) HasPart(part CocoPart) bool + func (h Human) PartCount() int + type MPIIPart int + const MPIIPartHead + const MPIIPartLAnkle + const MPIIPartLElbow + const MPIIPartLHip + const MPIIPartLKnee + const MPIIPartLShoulder + const MPIIPartLWrist + const MPIIPartNeck + const MPIIPartRAnkle + const MPIIPartRElbow + const MPIIPartRHip + const MPIIPartRKnee + const MPIIPartRShoulder + const MPIIPartRWrist + type ModelSize [2]int + var ModelSizeBest ModelSize = [2]int{ ... } + var ModelSizeBetter ModelSize = [2]int{ ... } + var ModelSizeCMU ModelSize = [2]int{ ... } + var ModelSizeDefault ModelSize = [2]int{ ... } + var ModelSizeFaster ModelSize = [2]int{ ... } + var ModelSizeFatest ModelSize = [2]int{ ... } + type ModelType int + const CMU + const MobileNet + type PartPair struct + CocoPart CocoPart + MPIIPart MPIIPart + type Point struct + X float64 + Y float64 + func BodyPartsPoints(parts []BodyPart) ([]Point, []bool) + func Pt(x float64, y float64) Point + func (p Point) IsZero() bool + type PoseEstimator struct + func NewPoseEstimator(modelPath string, modelType ModelType) *PoseEstimator + func (t *PoseEstimator) Estimate(img image.Image, modelSize ModelSize) ([]Human, error) + func (t *PoseEstimator) LoadModel() error + func (t *PoseEstimator) ModelLoaded() bool + func (t *PoseEstimator) SetSharpenSigma(sigma float64) + type Rectangle struct + H int + W int + X int + Y int + func Rect(x, y, w, h int) Rectangle + func (r Rectangle) Area() int + func (r Rectangle) Intersect(s Rectangle) Rectangle + type Size struct + H float64 + W float64 + func ASize(w, h float64) Size + func ImagePreprocess(img image.Image, modelSize ModelSize, sharpenSigma float64) (image.Image, Size) + func (s Size) IsZero() bool