Closed Yashar78 closed 1 year ago
how do you save it?
after calling the API : Path(output_file_name).write_text( response.text , encoding="utf-8")
try instead
Path(output_file_name).write_text( response.json() , encoding="utf-8")
It works now . Thanks a lot 👍
If I call the API ( nougatapi) to OCR a pdf and save it to a file and read it back , I see just a plain text, like "and a (1\times 1) pointwise convolution 2(c).\n\nA standard convolutional layer takes as input a (D{F}\times D{F}\times M) feature map (\mathbf{F}) and produces a (D{F}\times D{F}\times N) feature map (\mathbf{G}) where (D{F}) is the spatial width and height of a square input feature map1, (M) is" ,
which if I open it via the VS Code plugin I just see this plain text and no rendering of it. While if I do the same but this time via the nougat cli, then it is perfect and I can see the rendered formulas.
should I convert text to a specific format, which library ?