Update 16_2_Autoregressive_Flows.ipynb
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"source": [
|
||||
"# First let's make the 1D piecewise linear mapping as illustated in figure 16.5\n",
|
||||
"# First let's make the 1D piecewise linear mapping as illustrated in figure 16.5\n",
|
||||
"def g(h, phi):\n",
|
||||
" # TODO -- write this function (equation 16.12)\n",
|
||||
" # Note: If you have the first printing of the book, there is a mistake in equation 16.12\n",
|
||||
@@ -156,7 +156,7 @@
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"source": [
|
||||
"Now let's define an autogressive flow. Let's switch to looking at figure 16.7.# We'll assume that our piecewise function will use five parameters phi1,phi2,phi3,phi4,phi5"
|
||||
"Now let's define an autoregressive flow. Let's switch to looking at figure 16.7.# We'll assume that our piecewise function will use five parameters phi1,phi2,phi3,phi4,phi5"
|
||||
],
|
||||
"metadata": {
|
||||
"id": "t8XPxipfd7hz"
|
||||
@@ -175,7 +175,7 @@
|
||||
" x = x/ np.sum(x) ;\n",
|
||||
" return x\n",
|
||||
"\n",
|
||||
"# Return value of phi that doesn't depend on any of the iputs\n",
|
||||
"# Return value of phi that doesn't depend on any of the inputs\n",
|
||||
"def get_phi():\n",
|
||||
" return np.array([0.2, 0.1, 0.4, 0.05, 0.25])\n",
|
||||
"\n",
|
||||
|
||||
Reference in New Issue
Block a user