async detect(callback, ...args) 
	{
		
		// Create a new poseNet method with a single detection
		this.poseNet = await ml5.poseNet(this.media, this.modelReady);
		this.uNet = await ml5.uNet('face');
		
		
		// This sets up an event that fills the global variable "poses"
		// with an array every time new poses are detected
		this.poseNet.on('pose', (results) => {
			this.poses = results;
			
			if (this.settings.filter) {
				// initial segmentation
  				this.uNet.segment(this.media, (error, result) => this.filter(error, result));
			}

			this.prepareCanva(this);
			
			callback(this, ...args);
		});
		


    }
/* 
    * Promise that poseNet model and starts detection
	* @callback: callback method that we called through out detections
	* @...arg: any additional arguments passed will be passed to the callback
    */
Promise that poseNet model and starts detection
@callback: callback method that we called through out detections
@...arg: any additional arguments passed will be passed to the callback
Promise that poseNet model and starts detection @callback : callback method that we called through out detections @ ... arg : any additional arguments passed will be passed to the callback
async detect(callback, ...args) 
	{
		this.poseNet = await ml5.poseNet(this.media, this.modelReady);
		this.uNet = await ml5.uNet('face');
		this.poseNet.on('pose', (results) => {
			this.poses = results;
			if (this.settings.filter) {
  				this.uNet.segment(this.media, (error, result) => this.filter(error, result));
			}
			this.prepareCanva(this);
			callback(this, ...args);
		});
    }
async detect ( callback , ... args ) { this . poseNet = await ml5 . poseNet ( this . media , this . modelReady ) ; this . uNet = await ml5 . uNet ( 'face' ) ; this . poseNet . on ( 'pose' , ( results ) => { this . poses = results ; if ( this . settings . filter ) { this . uNet . segment ( this . media , ( error , result ) => this . filter ( error , result ) ) ; } this . prepareCanva ( this ) ; callback ( this , ... args ) ; } ) ; }
Promise that poseNet model and starts detection
 @callback: callback method that we called through out detections
 @...arg: any additional arguments passed will be passed to the callback
Promise that poseNet model and starts detection @callback : callback method that we called through out detections @ ... arg : any additional arguments passed will be passed to the callback
// Create a new poseNet method with a single detection // This sets up an event that fills the global variable "poses" // with an array every time new poses are detected // initial segmentation