Comments (4)
PAGE complaint XML file is saved by default in <work_dir>/results/<test,val,prod>/page/, to visualize the results I recommend Traskribus or nw-page-editor. Please see USAGE section on main README file, point 4.
from p2pala.
how to save as picture?can you give me some advice?
from p2pala.
Since document layout could be very complex I don't recommend to save it as a picture directly, but if you want just for baselines there is a script drawBaselines you can compile stand alone using g++ -o drawBaselines drawBaselines.cc -lopencv_imgproc -lopencv_core -lopencv_highgui -lpugixml
( libpugixml and opencv must be available in your system sudo apt-get install libpugixml-dev libopencv-dev
)
from p2pala.
Thanks for your comment!
In fact I understood zero-size unix symlinks on Windows last night..
I managed to visualize the resulting contours with the simple modification of gen_page() .
Added inside the l_cont loop :
cv2.drawContours(out_img, [l_cnt], 0, (0, 0, 255), 3)
I commented out symlinks generation and added after the .save_page()
cv2.imwrite(os.path.realpath( os.path.join(out_folder, img_name)), out_img)
where out_img is a copy of o_img.
That demonstrates red polygons around htr lines and it's quite enough for my purposes.
By the way - do you plan to publish any other models except ALAR?
Would be interesting to see.
In many cases the actual model can't recognise close verrtically adjacent lines. But generally the algorythm looks cool!
from p2pala.
Related Issues (20)
- [config] HOT 1
- evaluation HOT 1
- Different predictions when changing the images order in prod_img_list HOT 1
- Error when run pretrained model HOT 1
- JoseRPrietoF version? HOT 2
- TextLine region HOT 4
- XML generator HOT 5
- [Enhancement] Page-XML extractor HOT 2
- Weights initialisation error
- minor typo in command HOT 1
- error while running the pre trained model in google colab HOT 3
- Baseline + polygon detection of handwriting HOT 4
- Demo not working HOT 1
- Wights used on the Website demo HOT 1
- "Neural Networks based Model" link in docs not working HOT 1
- How to see output polygon drawn on an input image? HOT 4
- Does P2Pala support reading order? HOT 1
- Any chance to see more pre-trained models? HOT 2
- model for zone segmentation HOT 1
- require opencv-python-headless variant HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from p2pala.