diff --git a/notebooks/SBI_hierarchical_csv.ipynb b/notebooks/SBI_hierarchical_csv.ipynb index ecdbcfe..e600554 100644 --- a/notebooks/SBI_hierarchical_csv.ipynb +++ b/notebooks/SBI_hierarchical_csv.ipynb @@ -19,7 +19,7 @@ }, { "cell_type": "code", - "execution_count": 1, + "execution_count": 2, "id": "5e8c8f57", "metadata": {}, "outputs": [], @@ -38,7 +38,7 @@ }, { "cell_type": "code", - "execution_count": 2, + "execution_count": 3, "id": "4a76432d", "metadata": {}, "outputs": [ @@ -58,7 +58,7 @@ }, { "cell_type": "code", - "execution_count": 3, + "execution_count": 4, "id": "7bfe9a7f", "metadata": {}, "outputs": [], @@ -71,6 +71,19 @@ "import torch" ] }, + { + "cell_type": "code", + "execution_count": 15, + "id": "d24587bc-5777-41bb-b3b3-d1d63b7325c7", + "metadata": {}, + "outputs": [], + "source": [ + "# this is necessary to import modules from this repo\n", + "import sys\n", + "sys.path.append('..')\n", + "from src.scripts import models, utils, train" + ] + }, { "cell_type": "markdown", "id": "d478548e", @@ -82,7 +95,7 @@ }, { "cell_type": "code", - "execution_count": 8, + "execution_count": 5, "id": "6ff66af4-8bf4-4019-8c1a-8f0ef4428137", "metadata": {}, "outputs": [], @@ -117,7 +130,7 @@ }, { "cell_type": "code", - "execution_count": 9, + "execution_count": 6, "id": "37caacc2-d7ea-407e-9583-f94643976037", "metadata": {}, "outputs": [ @@ -142,7 +155,7 @@ }, { "cell_type": "code", - "execution_count": 10, + "execution_count": 7, "id": "6e5e4866-6cf1-40b9-93db-303988cbf8e2", "metadata": {}, "outputs": [], @@ -152,7 +165,7 @@ }, { "cell_type": "code", - "execution_count": 48, + "execution_count": 8, "id": "f7baa131-951c-4a69-a7c9-6f433afe6302", "metadata": {}, "outputs": [], @@ -168,6 +181,7 @@ "\n", "length_df = 1000\n", "thetas = np.zeros((length_df, 5))\n", + "# this needs to have the extra 1 so that SBI is happy\n", "xs = np.zeros((length_df,1))\n", "#labels = np.zeros((2*length_df, 2))\n", "#error = []\n", @@ -202,13 +216,13 @@ }, { "cell_type": "code", - "execution_count": 49, + "execution_count": 9, "id": "d1f15262-4b67-468a-8fd7-8f6578111f04", "metadata": {}, "outputs": [ { "data": { - "image/png": "iVBORw0KGgoAAAANSUhEUgAAAigAAAGdCAYAAAA44ojeAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjguMCwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy81sbWrAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAiaUlEQVR4nO3de3DU5f238XcOJJyyGwIkm2gIIEJAORUkbFWkkpKEeI5TQWrBYaBisKMRhVgEsR0TkamMDsjUqaAdkUpHsUKh0iDgIQRJoRzNABMLFDYgmWQJSjjkfv7ow85vJYCb7LJ3wvWa2TH57r1f7k/XbS43u0uEMcYIAADAIpHh3gAAAMAPESgAAMA6BAoAALAOgQIAAKxDoAAAAOsQKAAAwDoECgAAsA6BAgAArBMd7g00RUNDg44cOaK4uDhFRESEezsAAOBHMMbo5MmTSklJUWTk5Z8jaZGBcuTIEaWmpoZ7GwAAoAkOHTqk66+//rJrWmSgxMXFSfrfgA6HI8y7AQAAP4bX61Vqaqrv5/jltMhAufBrHYfDQaAAANDC/JiXZ/AiWQAAYJ2AAqWoqEi33HKL4uLilJiYqPvuu08VFRV+a0aOHKmIiAi/y2OPPea35uDBg8rNzVX79u2VmJioZ555RufOnWv+NAAAoFUI6Fc8GzduVH5+vm655RadO3dOzz33nEaPHq09e/aoQ4cOvnWTJ0/Wiy++6Pu+ffv2vq/Pnz+v3NxcuVwuffnllzp69Kh+9atfqU2bNnrppZeCMBIAAGjpIowxpqk3Pn78uBITE7Vx40aNGDFC0v+eQRk0aJAWLFjQ6G3WrFmju+66S0eOHFFSUpIkafHixZoxY4aOHz+umJiYK/65Xq9XTqdTtbW1vAYFAIAWIpCf3816DUptba0kKSEhwe/4u+++qy5duujmm29WYWGhvvvuO991paWl6t+/vy9OJCkrK0ter1e7d+9u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z6mrKzMd+yxxx4z3bp1M+vXrzdbt241brfbuN1u3/V/+9vfzJtvvml27txp9u3bZxYtWmTat29vZs+eHfJ5li9fbmJjY83SpUvNnj17zJQpU0x8fLzxeDzGGGMeeeQRM3PmTN/6L774wkRHR5v58+ebvXv3mjlz5jT6NuP4+Hjz0UcfmR07dph777037G+DC+aMJ0+eNNOnTzelpaWmsrLS/POf/zQ/+clPzI033mhOnz4dlhmNCXzO+vp6s23bNrNt2zaTnJxspk+fbrZt22b27dv3o895tYVixqefftps2LDBVFZWmi+++MJkZmaaLl26mGPHjl31+YwJfMbi4mITExNj/vrXv/q9LfPkyZN+a2x6TBoT/DltfFwGOuNLL71kPvnkE3PgwAGzZ88eM3/+fBMdHW3efPNN3xrb7stgzxiK+/GaCZQTJ06YcePGmY4dOxqHw2EeffRRv/8jqKysNJLMp59+6jv2/fffm8cff9x06tTJtG/f3tx///3m6NGjvuvXrFljBg0aZDp27Gg6dOhgBg4caBYvXmzOnz9/VWZ6/fXXTbdu3UxMTIwZNmyY2bx5s++6O+64w0yYMMFv/fvvv2969+5tYmJizE033WRWr17td31DQ4N5/vnnTVJSkomNjTWjRo0yFRUVV2OUSwrmjN99950ZPXq06dq1q2nTpo1JS0szkydPDtsP7f8rkDkv/Lv6w8sdd9zxo88ZDsGe8aGHHjLJyckmJibGXHfddeahhx4y+/fvv4oTXSyQGdPS0hqdcc6cOb41Nj4mjQnunLY+LgOZ8be//a3p1auXadu2renUqZNxu91m+fLlfuez8b4M5oyhuB8jjAnxe2IBAAAC1KJfgwIAAFonAgUAAFiHQAEAANYhUAAAgHUIFAAAYB0CBQAAWIdAAQAA1iFQAACAdQgUAABgHQIFAABYh0ABAADWIVAAAIB1/h8st7+O1N1AGwAAAABJRU5ErkJggg==", + "image/png": "iVBORw0KGgoAAAANSUhEUgAAAigAAAGdCAYAAAA44ojeAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjguMCwgaHR0cHM6Ly9tYXRwb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z5jT7NmOv1+veeust98knn7i77rrL1NvUor3mY8eOuenTp7tAIOCqqqrcP//5T/fd737XXXvtte7EiRNxWeM3RbrmxsZGt3XrVrd161bXvXt3N336dLd161a3e/fuiz6nBbFY92OPPeY2bNjgqqqq3IcffugKCgpc165d3eHDhy/7+poT6ZrnzZvn0tLS3F//+tewt9MeO3YsbIzlx7Rz0V93a3xc//a3v3Xvvvuu27t3r9uxY4dbsGCBS01NdS+++GJoTCLc1xerVQfK0aNH3fjx413Hjh2dx+Nx999/f9iDtqqqykly7733Xmjf119/7R566CHXuXNn1759e/eTn/zEHTp0KHT8nXfecUOGDHEdO3Z0HTp0cIMHD3ZLly51Z86cuZxLC7No0SLXo0cPl5aW5kaMGOE2b94cOnbzzTe7iRMnho1//fXXXb9+/VxaWpq7/vrr3Zo1a8KONzU1uaeeesplZ2e79PR0N2rUKLdr167LsZSLFs01f/XVV+62225z3bp1c23atHE9e/Z0U6ZMMfWL2rnI1nz23+1vbjfffPNFn9OKaK/73nvvdd27d3dpaWnuqquucvfee6/bs2fPZVzRt4tkzT179mx2zXPmzAmNSYTHtHPRXXdrfFz/6le/cn379nVt27Z1nTt3dn6/361YsSLsfIlyX1+MJOfi8P5YAACAC0i416AAAIDWj0ABAADmECgAAMAcAgUAAJhDoAAAAHMIFAAAYA6BAgAAzCFQAACAOQQKAAAwh0ABAADmECgAAMAcAgUAAJjz/wBW5ZmuC6VvaAAAAABJRU5ErkJggg==", "text/plain": [ "
" ] @@ -269,7 +283,7 @@ }, { "cell_type": "code", - "execution_count": 50, + "execution_count": null, "id": "f41fc285-883e-4313-bae2-e8e1c10a3e5b", "metadata": {}, "outputs": [ @@ -277,26 +291,12 @@ "name": "stdout", "output_type": "stream", "text": [ - "shape theta torch.Size([1000, 5])\n", - "shape x torch.Size([1000, 1])\n", - " Neural network successfully converged after 224 epochs." + " Training neural network. Epochs trained: 103" ] } ], "source": [ - "# Now let's put them in a tensor form that SBI can read.\n", - "theta = torch.tensor(thetas,dtype=torch.float32)#.reshape(100,1,5)\n", - "x = torch.tensor(xs,dtype=torch.float32)\n", "\n", - "print('shape theta', np.shape(theta))\n", - "print('shape x', np.shape(x))\n", - "#embedding_net = SummaryNet()\n", - "\n", - "# instantiate the neural density estimator\n", - "neural_posterior = sbi.utils.posterior_nn(model='maf')#,\n", - " #embedding_net=embedding_net,\n", - " #hidden_features=hidden_features,\n", - " #num_transforms=num_transforms)\n", "\n", "# make a fake prior\n", "# L, theta_0, a_g, mu, sigma\n", @@ -311,14 +311,9 @@ "prior_low = [0, jnp.pi / 1000, 0, 0, 0]\n", "prior_high = [10, jnp.pi / 10, 20, 20, 4]\n", "\n", - "prior = utils.BoxUniform(low=torch.tensor(prior_low), high=torch.tensor(prior_high), device='cpu')\n", - "\n", - "# setup the inference procedure with the SNPE-C procedure\n", - "inference = SNPE(prior=prior, density_estimator=neural_posterior, device=\"cpu\")\n", + "prior = sbi.utils.BoxUniform(low=torch.tensor(prior_low), high=torch.tensor(prior_high), device='cpu')\n", "\n", - "# Now that we have both the simulated images and parameters defined properly, we can train the SBI.\n", - "density_estimator = inference.append_simulations(theta,x).train()\n", - "posterior = inference.build_posterior(density_estimator)" + "posterior = train.train_SBI_hierarchical(thetas, xs, prior)" ] }, { diff --git a/src/scripts/train.py b/src/scripts/train.py index a24465b..9735959 100644 --- a/src/scripts/train.py +++ b/src/scripts/train.py @@ -3,6 +3,8 @@ Can leave a default data source, or specify that 'load data' loads the dataset used in the final version """ import argparse +import torch +import sbi def architecture(): @@ -29,6 +31,27 @@ def train_model(data_source, n_epochs): return 0 +def train_SBI_hierarchical(thetas, xs, prior): + # Now let's put them in a tensor form that SBI can read. + theta = torch.tensor(thetas, dtype=torch.float32) + x = torch.tensor(xs, dtype=torch.float32) + + # instantiate the neural density estimator + neural_posterior = sbi.utils.posterior_nn(model='maf')#, + #embedding_net=embedding_net, + #hidden_features=hidden_features, + #num_transforms=num_transforms) + # setup the inference procedure with the SNPE-C procedure + inference = sbi.inference.SNPE(prior=prior, + density_estimator=neural_posterior, + device="cpu") + + # now that we have both the simulated images and + # parameters defined properly, we can train the SBI. + density_estimator = inference.append_simulations(theta, x).train() + return inference.build_posterior(density_estimator) + + if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("--data_source", type=str, help="Data used to train the model")