NMAC427 / SwiftOCR

Fast and simple OCR library written in Swift
Apache License 2.0
4.61k stars 481 forks source link

Can't Invoke NSimage image in method SwiftOCRInstance.recognize! #163

Open ashutoshSharma12 opened 5 years ago

ashutoshSharma12 commented 5 years ago

AS I am trying to make a server side SwiftOCR when I convert the image data into image it returns the Exact image but When I'm trying to parse the Image in SwiftOCRInstace.recognize method it does not Convert the Image and Return null string my code is as below:

let newImage = NSImage(data: user.image)

     let newImage1 = OCRImage(newImage)
        let swiftOCRInstance = SwiftOCR()

        swiftOCRInstance.recognize((newImage)!){ recogniseString in        
        print(recogniseString)

        }
Coder-ACJHP commented 4 years ago

I'm facing same problem, it doesn't work, only prints

Using low GPU priority for background rendering.