Skip to content

Commit

Permalink
expanded readme
Browse files Browse the repository at this point in the history
  • Loading branch information
FlyingWorkshop committed Jan 5, 2025
1 parent e3d38aa commit 5144a97
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,18 @@ Y_compressed = compress(epca, Y)
Y_reconstructed = decompress(epca, Y_compressed)
```

The `sample_from_poisson` function is a placeholder for generating random Poisson-distributed data. It is not implemented in the code snippet to maintain clarity and focus on the core functionality of the example. If you wish to implement it, you can use the [`Distributions.jl`](https://github.com/JuliaStats/Distributions.jl) package. For instance, you could define it as:

```julia
using Distributions

function sample_from_poisson(n::Int, dim::Int)
d = Poisson()
rand(d, n, dim)
end
```


## Custom Distributions

When working with custom distributions, certain specifications are often more convenient and computationally efficient than others. For example, inducing the gamma EPCA objective from the log-partition $G(\theta) = -\log(-\theta)$ and its derivative $g(\theta) = -1/\theta$ is much simpler than implementing the full the Itakura-Saito distance:
Expand Down
4 changes: 2 additions & 2 deletions scripts/belief.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1697,15 +1697,15 @@
],
"metadata": {
"kernelspec": {
"display_name": "Julia 1.11.1",
"display_name": "Julia 1.11.2",
"language": "julia",
"name": "julia-1.11"
},
"language_info": {
"file_extension": ".jl",
"mimetype": "application/julia",
"name": "julia",
"version": "1.11.1"
"version": "1.11.2"
}
},
"nbformat": 4,
Expand Down

0 comments on commit 5144a97

Please sign in to comment.