Comments (5)
I don't understand why the sequence of good widgets should have an ascending order
There's nothing significant about the fact that the observed good widgets happen to be in ascending order.
Isn't it sufficient that all members of the good widgets are above the sampled threshold of the widget tester ?
IIRC the threshold is unknown. All we observe are the good widgets. The goal is to infer the distribution over the threshold, given the good widgets.
from probmods2.
if the order of the good widgets is unimportant because the size of the widgets is exchangeable, the condition should be "condition(0.5 < min(goodWidgetSeq))". I'll have to test whether this is syntactically correct. But you know what I mean. In this case you get the posterior P(Threshold | 0.5 < WidgetSize).
from probmods2.
Here is the modified condition for exchangeable widget-sizes. The condition checks whether all three members of the goodWidgetSeq are above or equal 0.6. Only in this case the threshold value is saved for the posterior distribution. As you can see, the results are even better than before:
var widgetDist = Infer({method: 'rejection', samples: 300, maxScore: -0.0}, function() {
var threshold = sample(thresholdPrior);
var goodWidgetSeq = makeWidgetSeq(3, threshold);
// condition(_.isEqual([.6, .7, .8], goodWidgetSeq)) // original code
condition(3*0.6 <= sum(goodWidgetSeq)) // new improved condition
return [threshold].join("");
})
from probmods2.
small error on my side :( of course the condition has on my side has to be:
var widgetDist = Infer({method: 'rejection', samples: 300}, function() {
var threshold = sample(thresholdPrior);
var goodWidgetSeq = makeWidgetSeq(3, threshold);
// condition(_.isEqual([.6, .7, .8], goodWidgetSeq))
condition(Math.pow(0.6, 3) <= product(goodWidgetSeq)) // new condition
return [threshold].join("");
})
from probmods2.
my last word:
var widgetDist = Infer({method: 'rejection', samples: 300}, function() {
var threshold = sample(thresholdPrior);
var goodWidgetSeq = makeWidgetSeq(3, threshold);
// condition(_.isEqual([.6, .7, .8], goodWidgetSeq))
condition(all(function(goodWidget){0.6 <= goodWidget}, goodWidgetSeq))
return [threshold].join("");
})
from probmods2.
Related Issues (20)
- Typos all over
- Readings page link seems broken HOT 1
- Unexpected use of `let` in WebPPL code box
- Migration to Gen? HOT 1
- Clarify LICENSE HOT 1
- Clarify model criticism section in bayesian data analysis chapter HOT 1
- chapter 9 / learning as Inference / de Finetti representation of Polya's urn
- Katex vs mathjax
- Make exercise pages nicer for working HW
- link on github repo is broken
- Marr's vision link is not found
- add exercise for process models chapter
- fix inference algorithms questions
- add additional scaffolding to distribution appendix
- flesh out rational process models chapter HOT 1
- clarify arithmetic generator in LoT chapter HOT 1
- updates to process model exercises
- updates to Occam's exercises
- Fix Occam's razor exercises
- fix mixture model exercises
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from probmods2.