Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > KOReader

Notices

Reply
 
Thread Tools Search this Thread
Old 07-10-2026, 06:03 PM   #31
embryo
Fanatic
embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.embryo calls his or her ebook reader Vera.
 
embryo's Avatar
 
Posts: 538
Karma: 64554
Join Date: Aug 2013
Device: Kobo Glo, GloHD
The app themes are great!!
Great improvement.
Really appreciate it..🙏

Quote:
Originally Posted by LegeApps View Post
The adaptive binarization default value change was really the big fix. I use fixed threshold a lot because I know the good values to pick (180 for dark color pages, 128 for light color pages) but I dont expect users to know that, and adaptive binarization is a more complex process that has its place.
For the Fixed Threshold and also for the Custom Adaptive values, you're right. The user can't know what is what (Custom adaptive doesn't even have a max/min value at the tooltip)..
So, the solution I propose is a drop-down menu (or some buttons if the GUI lib does not provide one), with 3-4 presets like "Cleaner text - Balanced - Cleaner background, or whatever the outcome is likely to be.
You know better than us what the values do, so you can name them in a helpful for the user way..

Quote:
Not sure what you mean. either you saw it using it in the CLI or it doesnt. The GPU is doing all it can do, I can guarantee that at this point. You should look at the code or ask a model to explain whats happening.

rendering=cpu via pdfium
resize=gpu where it helps
inference=gpu
binarization=gpu
encoding=cpu

This has all been nearly completely optimized.
I use GPU-Z to monitor the GPU's processing, memory, power draw, etc., but you can see it if you look at the Windows task manager (Performance>Cuda).
95% of the processing is for Preparing Pipeline / Initializing.
At this stage only 1 CPU thread is working (I have 8 cores - 16 threads). No GPU work at all.
After that its the Render | Infer | Encode stage that takes almost no time at all.
At this stage I see some spikes of GPU processing (only for some ms) and then it ends.
This is what I mean by "overall the processing was done at the CPU".
A great improvement would be if this was utilizing all the available threads, but maybe the library doesn't support this.

Quote:
That's not how the adaptive option works, it's a completely different binarizatio method than fixed threshold; it uses a fusion of Otsu and Sauvola which are two well known page binarization techniques. The "heavy model" is also Sauvola, but more intensive. I do not think implementing what you suggest would be coherent in code. What is the effect you are seeing in outputs that makes you want a feature like that?
As I said, I had to use the Fixed threshold because of the false letters that the adaptive was detecting.
I do thing that an adaptive mode would work better in a book with text and images of different brightness, since it will treat every page differently, but it might need some fine tuning like the book I mentioned.
If there is no such option, let's forget it..

Quote:
I did it in 1.4.61, I added dark modes based on color palettes I always wanted to add, from a Sanzo Wada color book. check them out in the new release. I think you'll like it.


Quote:
No nitpicking is what im here for, keep it up, as long as it's coherent nitpicking that I can act on. Thank you for your nitpicking.
OK then, more problems.

- Cropping is not working again.
It crops wherever it likes.
Turning the Layout detection Off, improves things sometimes, but not always.
I do recall that you said that you're gone set Free Aspect as default.
Well, I don't thing it is.
Even in the cases that cropping is almost working, all pages have almost the same size, even the ones that don't need to (a lot of blank space leftover)

- This is the taskbar icon of the app

and this is the app's window icon at dark themed Windows

It is almost impossible to be seen.
What I usually do for that, is to add a 1-pixel white (or light gray) runaround that is invisible at a light background, but shows the image if the background is dark..
Attached Thumbnails
Click image for larger version

Name:	L01.png
Views:	43
Size:	6.0 KB
ID:	224348   Click image for larger version

Name:	L02.png
Views:	42
Size:	7.2 KB
ID:	224349  
embryo is offline   Reply With Quote
Old Yesterday, 04:01 AM   #32
LegeApps
Member
LegeApps began at the beginning.
 
Posts: 13
Karma: 10
Join Date: Jun 2026
Device: Kobo Clara HD
https://github.com/LegeApp/Lege/rele...Lege-win64.zip

Quote:
Originally Posted by embryo View Post
The app themes are great!!
Great improvement.
Really appreciate it..��
Great..


Quote:
For the Fixed Threshold and also for the Custom Adaptive values, you're right. The user can't know what is what (Custom adaptive doesn't even have a max/min value at the tooltip)..
So, the solution I propose is a drop-down menu (or some buttons if the GUI lib does not provide one), with 3-4 presets like "Cleaner text - Balanced - Cleaner background, or whatever the outcome is likely to be.
You know better than us what the values do, so you can name them in a helpful for the user way..
In the documentation towards the end i explain what the options that I think are best for any given job..documentation can be seen from about page. it's been there since nearly the beginning of the program. I don't want to clutter the GUI with that stuff.


Quote:
I use GPU-Z to monitor the GPU's processing, memory, power draw, etc., but you can see it if you look at the Windows task manager (Performance>Cuda).
95% of the processing is for Preparing Pipeline / Initializing.
At this stage only 1 CPU thread is working (I have 8 cores - 16 threads). No GPU work at all.
After that its the Render | Infer | Encode stage that takes almost no time at all.
At this stage I see some spikes of GPU processing (only for some ms) and then it ends.
This is what I mean by "overall the processing was done at the CPU".
A great improvement would be if this was utilizing all the available threads, but maybe the library doesn't support this.
My custom GPU library is very high performance and doesn't need to use much GPU. I can guarantee that it is using your GPU if you have one. Just stick to reporting what you see versus what you would like to see, rather than what you think the code does, in the future, with any feedback reporting..i've spent so much time on multithreading. I'll indulge you for a second..:

pdfium - not threadsafe. behind a mutex. cannot be parallelized.
my custom onnx runtime can but if pdfium can't, it doesn't matter, everything downstream depends on pdfium. in PNG folder mode, the multithreading works. binarizing and encoding always fan out to threads.

Quote:
As I said, I had to use the Fixed threshold because of the false letters that the adaptive was detecting.
I do thing that an adaptive mode would work better in a book with text and images of different brightness, since it will treat every page differently, but it might need some fine tuning like the book I mentioned.
If there is no such option, let's forget it..
It already works per page, it never gets an entire book average. Why would a book have different brightness per page anyway? This just seems so complex for a user to use in the GUI that I have. Might as well use Scantailor if you need to do that.

Quote:

OK then, more problems.
- Cropping is not working again.
It crops wherever it likes.
Turning the Layout detection Off, improves things sometimes, but not always.
I do recall that you said that you're gone set Free Aspect as default.
Well, I don't thing it is.
Even in the cases that cropping is almost working, all pages have almost the same size, even the ones that don't need to (a lot of blank space leftover)
Fixed in 1.4.63. Thank you for the bug report. It was working on my test files. It works on even more now.

Quote:
- This is the taskbar icon of the app

and this is the app's window icon at dark themed Windows

It is almost impossible to be seen.
What I usually do for that, is to add a 1-pixel white (or light gray) runaround that is invisible at a light background, but shows the image if the background is dark..
I added a change for this, but if it doesn't show up, whatever.

But the big change this patch besides the backend stuff is grayscale mode, which should further address the "bad photocopy" complaint (i don't see it that way but thats ok). now there is an MRC based grayscale mode. It cleans the page via a different method than binarizing, then overlays a JBIG2 mask on top of the grayscale, so that the file size is only 20% larger than binarized output, and you get aliased text that looks better. It's not perfect but it's pretty good. Dare anyone to find a better one in a free program. I hope this will be the last version for awhile but something always comes up.

Last edited by LegeApps; Yesterday at 04:03 AM. Reason: typo
LegeApps is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Selective connections to Web rmanlee Library Management 4 02-02-2014 03:04 AM
Selective paragraph indent Leonatus Writer2ePub 8 10-31-2013 04:22 PM
Selective preprocess_regexps dasp Recipes 3 12-06-2011 08:52 AM
Selective format conversion? drmathprog Library Management 2 04-19-2011 08:43 AM
Selective exclusion of Hyperlinks SteffenH Sony Reader 4 10-03-2007 06:51 AM


All times are GMT -4. The time now is 06:18 PM.


MobileRead.com is a privately owned, operated and funded community.