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

about the crf model #23

Closed
huixiancheng opened this issue Nov 10, 2020 · 3 comments
Closed

about the crf model #23

huixiancheng opened this issue Nov 10, 2020 · 3 comments

Comments

@huixiancheng
Copy link

No description provided.

@huixiancheng
Copy link
Author

crf = PacCRF(21, num_steps=5, unary_weight=1.0)
crf.add_pairwise_kernel(kernel_size=5, dilation=1, blur=1, compat_type='4d', pairwise_weight=1.0)
edge_features = [paccrf.create_YXRGB(im, yx_scale=100.0, rgb_scale=30.0)]
output = crf(unary, edge_features)

dear ph.D, you use those code build a crf and then infer them.
however,i don't know the part of the build edge from two pairwise node since i'm noob could you tell me the part of the code? is it just like desecrf are all fullconnet?
or could i build a edge from two appointed points?

sry for in chinese:
尊敬的苏杭(?)博士:想问一下您的crf代码的边连接是参照densecrf进行全连接的吗?我能对指定两条点构建一条单独的edge吗?

@suhangpro
Copy link
Contributor

The connection pattern is defined by the add_pairwise_kernel line. For example, kernel_size=5 means that each pixel is connected with all the other 5 * 5 -1 pixels within its neighborhood.

@huixiancheng
Copy link
Author

thx,i will take a try

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