Commit d824b89e authored by Lucas Beyer's avatar Lucas Beyer Committed by GitHub
Browse files

Document how to get array from `Q`.

There was a sudden interest in this, both via issues (#23) and direct e-mail almost simultaneously. Odd 😄
parent e9291e90
...@@ -143,6 +143,14 @@ And the MAP prediction is then: ...@@ -143,6 +143,14 @@ And the MAP prediction is then:
map = np.argmax(Q, axis=0).reshape((640,480)) map = np.argmax(Q, axis=0).reshape((640,480))
``` ```
If you're interested in the class-probabilities `Q`, you'll notice `Q` is a
wrapped Eigen matrix. The Eigen wrappers of this project implement the buffer
interface and can be simply cast to numpy arrays like so:
```python
proba = np.array(Q)
```
Step-by-step inference Step-by-step inference
---------------------- ----------------------
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment