-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Performance on youtube video screenshot #10
Comments
Hey.
Thanks for getting in touch, nice to hear from you.
My algorithm will probably also fail on raw youtube material,
unfortunately.. The "rules-of-play" for the app are roughly as follows:
+ The input image must be square aspect ratio (will be resized to 512x512)
+ The image must be of a 2D representation of a single chessboard
+ All four corners of the chessboard must be inside the image
+ The chessboard must cover at least 60% of the image
So I am missing a pre-processing step that will crop out a square region of
the youtube video, where the above constraints are satisfied.
It's not quite trivial to implement, I have thought about it quite a bit,
but decided to work around it with a manual cropper widget (in my web-app
at least).
A possible solution would be some sort of region-of-interest or
object-detection with some auto-cropping algo.
Yeah, the state of the repo is a bit out of control, I wrote most of this 5
years ago when I had no idea how to code, going through it nowadays is a
bit painful and embarrassing..!
But I plan on improving and refactoring so it can be used by others more
simply. If you're interested I have built some python wheels that can be
simply pip-installed so you can try out the chessvision package (model
files are contained in the wheel). Or I can send you some hdf5 files with
the models.
On current master, you could run ml/train_square_classifier.py and
ml/train_board_extractor.py to train the models yourself. You would need to
comment out all the "wandb" stuff I recently added, as I was experimenting
with that..
G
…On Thu, Feb 23, 2023 at 2:14 AM Xidong Feng ***@***.***> wrote:
Nice work for chess vision detection! I want to know can your chessboard
detection U-net work well on Youtube videos? I want to detect the
chessboard in Youtube video screenshot but most open-sourced chess vision
projects fail to do that, because the noise in the image is large (things
other than the chessboard) and they cannot identify where the chessboard is.
In addition, I think the current README's instruction is out of date so
currently how can I run this project locally? Also the trained model
checkpoints seem missing here, are you willing to share them with me? Thank
you for your time!
—
Reply to this email directly, view it on GitHub
<#10>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABSDGR5YFSKR7LFUPJIEHZTWY22WLANCNFSM6AAAAAAVFARJAQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Hi, Thank you for your reply! It is really helpful for me to know more about when your model can work. Can you send me the hdf5 files for the piece classifier and board extractor? I am working on incorporating some chessboard detection solutions into the whole pipeline so I hope I can test the model locally. My email is xidong.feng.20@ucl.ac.uk, and really thank you for your help! |
Ok, I should have shared a onedrive folder with the model files now.
Don't have time to explain too much right now, the next week is my last
week of paternity leave so I have action-planned days ahead! Will follow up
next week and see how it goes.
Anyway, quick explanation. The small model can be loaded using the keras
"load_model" call. (the weights file also contains the model arch). The
large model you must first init the unet 256 architecture
(chessvision/model/u_net) and load the weights onto that.
Hope you make some sense of it, if not I'll try to help next week!
…On Mon, Feb 27, 2023 at 11:35 PM Xidong Feng ***@***.***> wrote:
Hi,
Thank you for your reply! It is really helpful for me to know more about
when your model can work. Can you send me the hdf5 files for the piece
classifier and board extractor? I am working on incorporating some
chessboard detection solutions into the whole pipeline so I hope I can test
the model locally.
My email is ***@***.***, and really thank you for your help!
—
Reply to this email directly, view it on GitHub
<#10 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABSDGR53LLEOMOFLNEKQVMTWZUT3FANCNFSM6AAAAAAVFARJAQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
OneDrive link: chessvision
<https://1drv.ms/u/s!AhIXpT3LbmMNlFu3uiyvXAO2qR2P?e=2rU4JG>
On Thu, Mar 2, 2023 at 7:23 AM Gudbrand Andreas Duff Morris Tandberg <
***@***.***> wrote:
… Ok, I should have shared a onedrive folder with the model files now.
Don't have time to explain too much right now, the next week is my last
week of paternity leave so I have action-planned days ahead! Will follow up
next week and see how it goes.
Anyway, quick explanation. The small model can be loaded using the keras
"load_model" call. (the weights file also contains the model arch). The
large model you must first init the unet 256 architecture
(chessvision/model/u_net) and load the weights onto that.
Hope you make some sense of it, if not I'll try to help next week!
On Mon, Feb 27, 2023 at 11:35 PM Xidong Feng ***@***.***>
wrote:
> Hi,
>
> Thank you for your reply! It is really helpful for me to know more about
> when your model can work. Can you send me the hdf5 files for the piece
> classifier and board extractor? I am working on incorporating some
> chessboard detection solutions into the whole pipeline so I hope I can test
> the model locally.
>
> My email is ***@***.***, and really thank you for your help!
>
> —
> Reply to this email directly, view it on GitHub
> <#10 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/ABSDGR53LLEOMOFLNEKQVMTWZUT3FANCNFSM6AAAAAAVFARJAQ>
> .
> You are receiving this because you commented.Message ID:
> ***@***.***>
>
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nice work for chess vision detection! I want to know can your chessboard detection U-net work well on Youtube videos? I want to detect the chessboard in Youtube video screenshot but most open-sourced chess vision projects fail to do that, because the noise in the image is large (things other than the chessboard) and they cannot identify where the chessboard is.
In addition, I think the current README's instruction is out of date so currently how can I run this project locally? Also the trained model checkpoints seem missing here, are you willing to share them with me? Thank you for your time!
The text was updated successfully, but these errors were encountered: