Skip to content
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

sliding window to extract patchs #8

Closed
haixpham opened this issue Sep 24, 2019 · 6 comments
Closed

sliding window to extract patchs #8

haixpham opened this issue Sep 24, 2019 · 6 comments

Comments

@haixpham
Copy link

Hi Delzac,
Do you know how to apply a sliding window, for example on image, to extract patches? I want to implement custom pooling op on each patch.

thx

@delzac
Copy link
Owner

delzac commented Sep 24, 2019

I know tensorflow has this function called extract_image_patches that does sliding window for images.

But i haven't thought of a way to implement it in cntk. It might not be possible with the python API or might be so inefficient that it is not worth trying :(

Duplicate #3752

@delzac delzac closed this as completed Sep 24, 2019
@delzac
Copy link
Owner

delzac commented Sep 24, 2019

@haixpham Actually this might be what you are looking for! Found it in this cntk issue #2819. It creates a sliding window for image.

@delzac
Copy link
Owner

delzac commented Sep 24, 2019

@haixpham Let me know if it works and how is the performance. I may add it in cntkx.

@haixpham
Copy link
Author

the code from there does not work, it raises RuntimeError. I will spend time brainstorming on a solution.

@haixpham
Copy link
Author

haixpham commented Sep 24, 2019

I ended up not extracting patches explicitly, and came up with an efficient implementation of median filter. Tested it and it works as intended. See my post on CNTK forum for details.

P.S: I will continue using CNTK in my work. Have tried other frameworks but CNTK is still the best with its current feature set, especially dynamic sequence axis. Would you mind if I join in developing cntkx?

@delzac
Copy link
Owner

delzac commented Sep 24, 2019

It's great to hear that you managed to solve the problem, I definitely take a took at your implementation to learn from it!!

I'm personally still using CNTK because of the dynamic axis too! I would love to have you join in in developing cntkx, more than welcome!!! ❤️❤️❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants