Post not yet marked as solved
This video example can not find all the code, some details have doubts, I would like to ask you to help me, thank you very much!
email: wu.shaopeng@aol.
Please forgive me, this mailbox also has (com)
Post not yet marked as solved
Hi everyone I'm trying to use createML hand action classifier to detect some simple actions, I'm having some trouble because the model only detects one hand at a time in the scene(even in the preview of the model, without any coding) and I would need both hands, is it a bug or am I doing something wrong?
Thank you in advance
Post not yet marked as solved
After creating a custom action classifier in Create ML, previewing it (see the bottom of the page) with an input video shows the label associated with a segment of the video. What would be a good way to store the duration for a given label, say, each CMTimeRange of segment of video frames that are classified as containing "Jumping Jacks?"
I previously found that storing time ranges of trajectory results was convenient, since each VNTrajectoryObservation vended by Apple had an associated CMTimeRange.
However, using my custom action classifier instead, each VNObservation result's CMTimeRange has a duration value that's always 0.
func completionHandler(request: VNRequest, error: Error?) {
guard let results = request.results as? [VNHumanBodyPoseObservation] else {
return
}
if let result = results.first {
storeObservation(result)
}
do {
for result in results where try self.getLastTennisActionType(from: [result]) == .playing {
var fileRelativeTimeRange = result.timeRange
fileRelativeTimeRange.start = fileRelativeTimeRange.start - self.assetWriterStartTime
self.timeRangesOfInterest[Int(fileRelativeTimeRange.start.seconds)] = fileRelativeTimeRange
}
} catch {
print("Unable to perform the request: \(error.localizedDescription).")
}
}
In this case I'm interested in frames with the label "Playing" and successfully classify them, but I'm not sure where to go from here to track the duration of video segments with consecutive frames that have that label.
Post not yet marked as solved
I'm building a feature to automatically edit out all the downtime of a tennis video. I have a partial implementation that stores the start and end times of Vision trajectory detections and writes only those segments to an AVFoundation export session.
I've encountered a major issue, which is that the trajectories returned end whenever the ball bounce, so each segment is just one tennis shot and nowhere close to an entire rally with multiple bounces. I'm ensure if I should continue done the trajectory route, maybe stitching together the trajectories and somehow only splitting at the start and end of a rally.
Any general guidance would be appreciated.
Is there a different Vision or ML approach that would more accurately model the start and end time of a rally? I considered creating a custom action classifier to classify frames to be either "playing tennis" or "inactivity," but I started with Apple's trajectory detection since it was already built and trained. Maybe a custom classifier would be needed, but not sure.
Post not yet marked as solved
I just created my custom hand poses classification ml model and I don't know how to implement it in any app..So where can I get the demo app that they showed us in the video?
Post not yet marked as solved
Pardon my ignorance but how does one obtain image classification data to create your model?
Post not yet marked as solved
I have watched the 'Classify hand poses and actions with Create ML' from WWDC2021
I was able to create a model using the Create ML app.
But I am not sure how to use it in my iOS project. The video above misses out several steps.
I have the HandPoseRequest working and can get the MLMultiArray of points. I have added the model file to my project and can create a MLModel instance from it.
But the video above shows:
let handPosePredition = try model.prediction(poses: keypointsMultiArray)
What is the type of model ?
How was it created?
I cannot find any model type that has a function prediction(poses: MLMultiarray)
Thanks.