Forming conditional distributions in TensorFlow probability
I am using Tensorflow Probability to build a VAE which includes image pixels as well as some other variables. The output of the VAE:
tfp.distributions.Independent(tfp.distributions.Bernoulli(logits), 2, name="decoder-dist")
I am trying to understand how to form other conditional distributions based on this which I can use with the inference methods (MCMC or VI). Say the output above was P(A,B,C | Z), how would I take that distribution to form a posterior P(A|B, C, Z) that I could perform inference on? I have been trying to read through the docs but I am having some trouble grasping them.
tensorflow machine-learning autoencoder tensorflow-probability
add a comment |
I am using Tensorflow Probability to build a VAE which includes image pixels as well as some other variables. The output of the VAE:
tfp.distributions.Independent(tfp.distributions.Bernoulli(logits), 2, name="decoder-dist")
I am trying to understand how to form other conditional distributions based on this which I can use with the inference methods (MCMC or VI). Say the output above was P(A,B,C | Z), how would I take that distribution to form a posterior P(A|B, C, Z) that I could perform inference on? I have been trying to read through the docs but I am having some trouble grasping them.
tensorflow machine-learning autoencoder tensorflow-probability
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31
add a comment |
I am using Tensorflow Probability to build a VAE which includes image pixels as well as some other variables. The output of the VAE:
tfp.distributions.Independent(tfp.distributions.Bernoulli(logits), 2, name="decoder-dist")
I am trying to understand how to form other conditional distributions based on this which I can use with the inference methods (MCMC or VI). Say the output above was P(A,B,C | Z), how would I take that distribution to form a posterior P(A|B, C, Z) that I could perform inference on? I have been trying to read through the docs but I am having some trouble grasping them.
tensorflow machine-learning autoencoder tensorflow-probability
I am using Tensorflow Probability to build a VAE which includes image pixels as well as some other variables. The output of the VAE:
tfp.distributions.Independent(tfp.distributions.Bernoulli(logits), 2, name="decoder-dist")
I am trying to understand how to form other conditional distributions based on this which I can use with the inference methods (MCMC or VI). Say the output above was P(A,B,C | Z), how would I take that distribution to form a posterior P(A|B, C, Z) that I could perform inference on? I have been trying to read through the docs but I am having some trouble grasping them.
tensorflow machine-learning autoencoder tensorflow-probability
tensorflow machine-learning autoencoder tensorflow-probability
edited Nov 25 '18 at 2:28
taylormade201
asked Nov 21 '18 at 22:13
taylormade201taylormade201
2661520
2661520
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31
add a comment |
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31
add a comment |
1 Answer
1
active
oldest
votes
The answer to your question depends very much on the nature of the joint model within which you'd like to do the conditioning. Much has been written about the topic, and in short it's a very hard problem in general :). Without knowing a bit more about the particulars of your problem, it's near impossible to recommend a useful generic inference procedure. However, we do have a bunch of examples (scripts and jupyter/colab notebooks) in the TFP repo here: https://github.com/tensorflow/probability/tree/master/tensorflow_probability/examples
In particular, there's
The Hierarchical Linear Model example, which is a sort of Rosetta stone showing how to do posterior inference using Hamiltonian Monte Carlo (an MCMC technique) in TFP, R, and Stan,
The Linear Mixed Effects Model example, showing how you might use VI to solve a standard LME problem,
among many others. You can click the "Run in Google Colab" link at the top of any of these notebooks to open and run on them on https://colab.research.google.com.
Please feel free, also, to reach out on to us via email at tfprobability@tensorflow.org. This is a public Google Group where users can engage with the team that builds TFP directly. If you provide us some more info there on what you'd like to do, we're happy to provide guidance on modeling and inference with TFP.
Hope this is gives at least a start in the right direction!
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53421179%2fforming-conditional-distributions-in-tensorflow-probability%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
The answer to your question depends very much on the nature of the joint model within which you'd like to do the conditioning. Much has been written about the topic, and in short it's a very hard problem in general :). Without knowing a bit more about the particulars of your problem, it's near impossible to recommend a useful generic inference procedure. However, we do have a bunch of examples (scripts and jupyter/colab notebooks) in the TFP repo here: https://github.com/tensorflow/probability/tree/master/tensorflow_probability/examples
In particular, there's
The Hierarchical Linear Model example, which is a sort of Rosetta stone showing how to do posterior inference using Hamiltonian Monte Carlo (an MCMC technique) in TFP, R, and Stan,
The Linear Mixed Effects Model example, showing how you might use VI to solve a standard LME problem,
among many others. You can click the "Run in Google Colab" link at the top of any of these notebooks to open and run on them on https://colab.research.google.com.
Please feel free, also, to reach out on to us via email at tfprobability@tensorflow.org. This is a public Google Group where users can engage with the team that builds TFP directly. If you provide us some more info there on what you'd like to do, we're happy to provide guidance on modeling and inference with TFP.
Hope this is gives at least a start in the right direction!
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
add a comment |
The answer to your question depends very much on the nature of the joint model within which you'd like to do the conditioning. Much has been written about the topic, and in short it's a very hard problem in general :). Without knowing a bit more about the particulars of your problem, it's near impossible to recommend a useful generic inference procedure. However, we do have a bunch of examples (scripts and jupyter/colab notebooks) in the TFP repo here: https://github.com/tensorflow/probability/tree/master/tensorflow_probability/examples
In particular, there's
The Hierarchical Linear Model example, which is a sort of Rosetta stone showing how to do posterior inference using Hamiltonian Monte Carlo (an MCMC technique) in TFP, R, and Stan,
The Linear Mixed Effects Model example, showing how you might use VI to solve a standard LME problem,
among many others. You can click the "Run in Google Colab" link at the top of any of these notebooks to open and run on them on https://colab.research.google.com.
Please feel free, also, to reach out on to us via email at tfprobability@tensorflow.org. This is a public Google Group where users can engage with the team that builds TFP directly. If you provide us some more info there on what you'd like to do, we're happy to provide guidance on modeling and inference with TFP.
Hope this is gives at least a start in the right direction!
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
add a comment |
The answer to your question depends very much on the nature of the joint model within which you'd like to do the conditioning. Much has been written about the topic, and in short it's a very hard problem in general :). Without knowing a bit more about the particulars of your problem, it's near impossible to recommend a useful generic inference procedure. However, we do have a bunch of examples (scripts and jupyter/colab notebooks) in the TFP repo here: https://github.com/tensorflow/probability/tree/master/tensorflow_probability/examples
In particular, there's
The Hierarchical Linear Model example, which is a sort of Rosetta stone showing how to do posterior inference using Hamiltonian Monte Carlo (an MCMC technique) in TFP, R, and Stan,
The Linear Mixed Effects Model example, showing how you might use VI to solve a standard LME problem,
among many others. You can click the "Run in Google Colab" link at the top of any of these notebooks to open and run on them on https://colab.research.google.com.
Please feel free, also, to reach out on to us via email at tfprobability@tensorflow.org. This is a public Google Group where users can engage with the team that builds TFP directly. If you provide us some more info there on what you'd like to do, we're happy to provide guidance on modeling and inference with TFP.
Hope this is gives at least a start in the right direction!
The answer to your question depends very much on the nature of the joint model within which you'd like to do the conditioning. Much has been written about the topic, and in short it's a very hard problem in general :). Without knowing a bit more about the particulars of your problem, it's near impossible to recommend a useful generic inference procedure. However, we do have a bunch of examples (scripts and jupyter/colab notebooks) in the TFP repo here: https://github.com/tensorflow/probability/tree/master/tensorflow_probability/examples
In particular, there's
The Hierarchical Linear Model example, which is a sort of Rosetta stone showing how to do posterior inference using Hamiltonian Monte Carlo (an MCMC technique) in TFP, R, and Stan,
The Linear Mixed Effects Model example, showing how you might use VI to solve a standard LME problem,
among many others. You can click the "Run in Google Colab" link at the top of any of these notebooks to open and run on them on https://colab.research.google.com.
Please feel free, also, to reach out on to us via email at tfprobability@tensorflow.org. This is a public Google Group where users can engage with the team that builds TFP directly. If you provide us some more info there on what you'd like to do, we're happy to provide guidance on modeling and inference with TFP.
Hope this is gives at least a start in the right direction!
answered Nov 26 '18 at 22:49
Chris SuterChris Suter
471148
471148
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
add a comment |
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
1
1
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
Thanks Chris, I really appreciate your reply. After thinking about it a lot, I don't think I am forming the right problem or even asking the right question. I will make a new, more detailed post on the Google group and hopefully get some guidance from the community. Thanks again!
– taylormade201
Nov 27 '18 at 22:58
1
1
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
I posted the re-formulated question here groups.google.com/a/tensorflow.org/forum/#!topic/tfprobability/… Thanks again for the help
– taylormade201
Nov 27 '18 at 23:23
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53421179%2fforming-conditional-distributions-in-tensorflow-probability%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Anyone know if I can increase the bounty on this after its been set? I would really appreciate some help getting this answered.
– taylormade201
Nov 25 '18 at 0:31