-
Notifications
You must be signed in to change notification settings - Fork 9
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
Poon-Domingos structure in LibSPN-Keras #38
Comments
Thanks for raising this. I admit with the current state of the library that's going to be a complicated thing to do. The If the SPN can be expressed as N sub-SPNs, each having its own decomposition, then you could repeatedly call the I think I'd have to build more tooling for this in the library to get this to work. I will get back to you in a few days and give it some thought. |
Thank you for considering this! |
I have given it some thought and had a shot at an initial draft implementation. I think I know what piece to add to the puzzle. A convenient way of achieving this would be to use another type of
Notice the new Here there are just two splits. For the Poon & Domingos architecture, you'd need way more. I'm working on tooling to transform this kind of region graph to a stack of Keras layers. Will keep you posted. |
I managed to complete the conversion, but I'm afraid that a single stack of Keras layers would require lots and lots of zero padding. For a 4x4 block (the finer regions in the Poon & Domingos have that size), this results in about 90% of leaf variables being padded. Perhaps alternatively, the way to do it is to make a non- |
I am trying to implement the Poon-Domingos structure for spatial data in LibSPN-Keras, as introduced in their seminal 2011 paper Sum-product networks: A new deep architecture. While a Poon-Domingos is structurally similar to a RAT-SPN (like in this example), the splits should not be made at random, but based on the spatial structure of the data.
How could I go about recreating the Poon-Domingos structure in LibSPN-Keras? I first tried region graphs with
region_graph_to_dense_spn
, but then the generated SPN only has a single decomposition. An alternative approach I thought of is using aPermuteAndPadScopes
layer, but I am not sure how I should define thepermutations
parameter.Do you know what would be a good approach for implementing the Poon-Domingos structure in LibSPN-Keras? Thank you!
The text was updated successfully, but these errors were encountered: