Package: libspn
LibSPNLibSPN is a library for learning and inference with Sum-Product Networks. LibSPN
is integrated withTensorFlow.What are SPNs?Sum-Product Networks (SPNs) are a probabilistic deep architecture with solid theoretical foundations, which demonstrated state-of-the-art performance in several domains. Yet, surprisingly, there are no mature, general-purpose SPN implementations that would serve as a platform for the community of machine learning researchers centered around SPNs. LibSPN is a new general-purpose Python library, which aims to become such a platform. The library is designed to make it straightforward and effortless to apply various SPN architectures to large-scale datasets and problems. The library achieves scalability and efficiency, thanks to a tight coupling with TensorFlow, a framework already used by a large community of researchers and developers in multiple domains.Why LibSPN?Several reasons:LibSPN is a general-purpose library with a generic interface and tools for generating SPN structure, making it easy to apply SPNs to any domain/problemLibSPN offers a simple Python interface for building or generating networks, learning, and inference, facilitating prototyping (e.g. in Jupyter) and enabling simple integration of SPNs with other softwareLibSPN is integrated with TensorFlow, making it possible to combine SPNs with other deep learning methodsLibSPN uses concepts that should sound familiar to TensorFlow users (e.g. tensors, variables, feeding, queues, batching, TensorBoard etc.)LibSPN leverages the power of TensorFlow to efficiently perform parallel computations on (multiple) GPU devicesLibSPN is extendable, making it easy to add custom operations and graph nodesInstallationPrerequisitesLibSPN requires installingtensorflowandtensorflow-probabilityfirst. The table below shows
which version of each you'd need if you want to be specific:tensorflowtensorflow-probability1.140.7.01.130.6.01.120.5.01.110.4.0First, installtensorflowortensorflow-gpu:pipinstalltensorflow-gpuThen, installtensorflow-probability:pipinstalltensorflow-probabilityLibSPNLibSPN is also available onpypi:pipinstalllibspnFeatures of LibSPNSimple interface for manual creation of custom network architecturesAutomatic SPN validity checking and scope calculationAdding explicit latent variables to sums/mixturesWeight sharingIntegration with TensorFlowSPN graph is converted to TensorFlow graph realizing specific algorithms/computationsInputs to the network come from TensorFlow feeds or any TensorFlow tensorsSPN structure generation and learningDense random SPN generatorSimple naive Bayes mixture model generatorLoading and saving of structure and weights of learned modelsSimple interface for random data generation, data loading and batchingRandom data sampling from Gaussian MixturesUsing TensorFlow queues for data loading, shuffling and batchingBuilt-in visualizationsSPN graph structure visualizationData/distribution visualizationsSPN InferenceSPN/MPN value calculationGradient calculationInferring MPE statePapers using LibSPNDeep Convolutional Sum-Product Networks for Probabilistic Image RepresentationsJos van de Wolfshaar, Andrzej Pronobis(2019).From Pixels to Buildings: End-to-end Probabilistic Deep Networks for Large-scale Semantic MappingKaiyu Zheng, Andrzej Pronobis(2018)Learning Graph-Structured Sum-Product Networks for Probabilistic Semantic MapsKaiyu Zheng, Andrzej Pronobis, Rajesh P. N. Rao(2018)Learning Deep Generative Spatial Models For Mobile RobotsAndrzej Pronobis, Rajesh P. N. Rao(2017)Learning Semantic Maps With Topological ReasoningKaiyu Zheng, Andrzej Pronobis, Rajesh P. N. Rao(2017)