From 1114d2b2eda05f42dd619b6ea71de3b928a906ed Mon Sep 17 00:00:00 2001 From: Jonas Eschle Date: Tue, 9 Jan 2024 12:33:41 -0500 Subject: [PATCH] ci: update pre-commit cleaning --- .../components/20 - Composite Models.ipynb | 13 +- .../components/60 - Custom PDF.ipynb | 6 +- .../90 - Serialization basics.ipynb | 211 ++--------- ...nts_simultaneous_fit_discovery_splot.ipynb | 267 ++----------- _website/tutorials/guides/custom_models.ipynb | 3 +- .../tutorials/introduction/Introduction.ipynb | 351 +----------------- components/20 - Composite Models.ipynb | 13 +- components/60 - Custom PDF.ipynb | 6 +- components/90 - Serialization basics.ipynb | 211 ++--------- ...nts_simultaneous_fit_discovery_splot.ipynb | 267 ++----------- guides/custom_models.ipynb | 3 +- introduction/Introduction.ipynb | 351 +----------------- 12 files changed, 164 insertions(+), 1538 deletions(-) diff --git a/_website/tutorials/components/20 - Composite Models.ipynb b/_website/tutorials/components/20 - Composite Models.ipynb index 8c289c1..761f3d5 100644 --- a/_website/tutorials/components/20 - Composite Models.ipynb +++ b/_website/tutorials/components/20 - Composite Models.ipynb @@ -159,12 +159,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T16:13:03.168140846Z", - "start_time": "2023-10-08T16:13:02.852036292Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "extended_gauss_method = gauss3.create_extended(yield1)" @@ -173,13 +168,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "gauss3_ext = zfit.pdf.Gauss(obs=obs2, mu=mu3, sigma=sigma3, extended=yield1)" - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/_website/tutorials/components/60 - Custom PDF.ipynb b/_website/tutorials/components/60 - Custom PDF.ipynb index f70ebec..8c5c051 100644 --- a/_website/tutorials/components/60 - Custom PDF.ipynb +++ b/_website/tutorials/components/60 - Custom PDF.ipynb @@ -172,12 +172,10 @@ }, { "cell_type": "markdown", + "metadata": {}, "source": [ "More advanced custom PDFs are introduced in the guide on [custom PDFs](custom_pdfs.ipynb)." - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/_website/tutorials/components/90 - Serialization basics.ipynb b/_website/tutorials/components/90 - Serialization basics.ipynb index a8dbaff..18365e0 100644 --- a/_website/tutorials/components/90 - Serialization basics.ipynb +++ b/_website/tutorials/components/90 - Serialization basics.ipynb @@ -19,10 +19,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.279440915Z", - "start_time": "2023-07-04T09:13:44.218982607Z" - }, "jupyter": { "outputs_hidden": false } @@ -46,10 +42,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.344315600Z", - "start_time": "2023-07-04T09:13:44.224966703Z" - }, "jupyter": { "outputs_hidden": false } @@ -66,10 +58,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.626719682Z", - "start_time": "2023-07-04T09:13:44.314016788Z" - }, "jupyter": { "outputs_hidden": false } @@ -84,10 +72,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.630490029Z", - "start_time": "2023-07-04T09:13:44.628116302Z" - }, "jupyter": { "outputs_hidden": false } @@ -101,10 +85,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.078062754Z", - "start_time": "2023-07-04T09:13:44.634012974Z" - }, "jupyter": { "outputs_hidden": false } @@ -125,10 +105,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.081724535Z", - "start_time": "2023-07-04T09:13:45.079081658Z" - }, "jupyter": { "outputs_hidden": false } @@ -143,10 +119,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.089182199Z", - "start_time": "2023-07-04T09:13:45.084547906Z" - }, "jupyter": { "outputs_hidden": false } @@ -160,10 +132,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.286143190Z", - "start_time": "2023-07-04T09:13:45.089906166Z" - }, "jupyter": { "outputs_hidden": false } @@ -180,10 +148,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.286381522Z", - "start_time": "2023-07-04T09:13:45.110205375Z" - }, "jupyter": { "outputs_hidden": false } @@ -207,12 +171,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.287047511Z", - "start_time": "2023-07-04T09:13:45.151818465Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "model.to_dict()" @@ -221,12 +180,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.287692092Z", - "start_time": "2023-07-04T09:13:45.195475042Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "mu.to_dict()" @@ -235,12 +189,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288178006Z", - "start_time": "2023-07-04T09:13:45.195679267Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "obs.to_dict()" @@ -258,12 +207,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288744487Z", - "start_time": "2023-07-04T09:13:45.195824685Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "gauss2 = model.from_dict(model.to_dict()) # effectively creates a copy (parameters are shared!)\n", @@ -280,12 +224,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288945771Z", - "start_time": "2023-07-04T09:13:45.243618137Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "gauss3 = zfit.pdf.Gauss.from_dict(model.to_dict())" @@ -303,12 +242,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.289701922Z", - "start_time": "2023-07-04T09:13:45.243850081Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "sigma.to_json()" @@ -317,12 +251,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.290281402Z", - "start_time": "2023-07-04T09:13:45.244018144Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "sigma.to_yaml()" @@ -340,12 +269,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.294861384Z", - "start_time": "2023-07-04T09:13:45.244174736Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data.to_dict()" @@ -361,12 +285,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.307383710Z", - "start_time": "2023-07-04T09:13:45.287498620Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "try:\n", @@ -385,12 +304,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.507248332Z", - "start_time": "2023-07-04T09:13:45.287858472Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf = data.to_asdf()\n", @@ -413,12 +327,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.554688217Z", - "start_time": "2023-07-04T09:13:45.499563339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf.tree" @@ -427,24 +336,14 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.554984413Z", - "start_time": "2023-07-04T09:13:45.547805565Z" - } - }, + "metadata": {}, "outputs": [], "source": [] }, { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.555197569Z", - "start_time": "2023-07-04T09:13:45.548139660Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf.write_to(\"data.asdf\") # Will create a file in the current directory" @@ -460,12 +359,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:46.272975151Z", - "start_time": "2023-07-04T09:13:45.548407961Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "!head -25 data.asdf" @@ -474,12 +368,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.001598595Z", - "start_time": "2023-07-04T09:13:46.251157486Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "!wc -l data.asdf # the file is about 471 lines long, filled with binary" @@ -495,12 +384,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.064629808Z", - "start_time": "2023-07-04T09:13:47.005462375Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "import asdf\n", @@ -513,12 +397,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.093193817Z", - "start_time": "2023-07-04T09:13:47.067703370Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data.value()" @@ -527,12 +406,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.094131819Z", - "start_time": "2023-07-04T09:13:47.082251988Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# cleanup of the file\n", @@ -560,12 +434,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.160512923Z", - "start_time": "2023-07-04T09:13:47.087043035Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.dumps(model)" @@ -574,12 +443,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.172729691Z", - "start_time": "2023-07-04T09:13:47.127529113Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3obj = zfit.hs3.loads(zfit.hs3.dumps(model))" @@ -588,12 +452,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.173480212Z", - "start_time": "2023-07-04T09:13:47.172020303Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "list(hs3obj['distributions'].values())" @@ -611,12 +470,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.319939293Z", - "start_time": "2023-07-04T09:13:47.172476842Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped = zfit.hs3.dumps(model)\n", @@ -626,12 +480,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.511521384Z", - "start_time": "2023-07-04T09:13:47.308345461Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped = zfit.hs3.dumps(loss)\n", @@ -641,12 +490,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.543604166Z", - "start_time": "2023-07-04T09:13:47.535423644Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped" @@ -655,12 +499,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.672205748Z", - "start_time": "2023-07-04T09:13:47.535685300Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.loads(hs3dumped)" diff --git a/_website/tutorials/guides/constraints_simultaneous_fit_discovery_splot.ipynb b/_website/tutorials/guides/constraints_simultaneous_fit_discovery_splot.ipynb index 6228cf1..f53672f 100644 --- a/_website/tutorials/guides/constraints_simultaneous_fit_discovery_splot.ipynb +++ b/_website/tutorials/guides/constraints_simultaneous_fit_discovery_splot.ipynb @@ -27,12 +27,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489215542Z", - "start_time": "2023-10-08T14:12:39.756038115Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "import hepunits as u\n", @@ -49,12 +44,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489484263Z", - "start_time": "2023-10-08T14:12:39.843646064Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "mu_true = lp.B_plus.mass * u.MeV\n", @@ -68,12 +58,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489628044Z", - "start_time": "2023-10-08T14:12:39.888112598Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# create some data\n", @@ -85,12 +70,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489915684Z", - "start_time": "2023-10-08T14:12:39.888213619Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Firstly, the observable and its range is defined\n", @@ -100,12 +80,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.490043904Z", - "start_time": "2023-10-08T14:12:39.936032491Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# load data into zfit\n", @@ -115,12 +90,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.505837597Z", - "start_time": "2023-10-08T14:12:39.981346354Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Parameters are specified: (name (unique), initial, lower, upper) whereas lower, upper are optional\n", @@ -145,12 +115,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.506011519Z", - "start_time": "2023-10-08T14:12:40.028065418Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "constraint = zfit.constraint.GaussianConstraint(mu, observation=5275 * u.MeV, uncertainty=15 * u.MeV)" @@ -159,12 +124,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.005963419Z", - "start_time": "2023-10-08T14:12:40.028138339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "nll = zfit.loss.ExtendedUnbinnedNLL(model, data, constraints=constraint)\n", @@ -176,12 +136,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.052831330Z", - "start_time": "2023-10-08T14:12:41.007823487Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result.params)" @@ -211,12 +166,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.052995596Z", - "start_time": "2023-10-08T14:12:41.052115586Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "n_sig_reso = 40000\n", @@ -226,12 +176,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133459640Z", - "start_time": "2023-10-08T14:12:41.052211792Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# create some data\n", @@ -277,12 +222,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133682724Z", - "start_time": "2023-10-08T14:12:41.100105831Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Firstly, we create a free scaling parameter\n", @@ -302,12 +242,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133773368Z", - "start_time": "2023-10-08T14:12:41.100194140Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "signal_reso = zfit.pdf.Gauss(mu=mu, # the same as for the rare mode\n", @@ -345,12 +280,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:42.214580213Z", - "start_time": "2023-10-08T14:12:41.100235132Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "nll_rare = zfit.loss.ExtendedUnbinnedNLL(model, data)\n", @@ -361,12 +291,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:42.264410782Z", - "start_time": "2023-10-08T14:12:42.221507568Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "extended_sig_reso.get_yield()" @@ -375,12 +300,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.102306848Z", - "start_time": "2023-10-08T14:12:42.264125616Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "result_simultaneous = minimizer.minimize(nll_simultaneous)" @@ -389,12 +309,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.551062544Z", - "start_time": "2023-10-08T14:12:45.073654511Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "result_simultaneous.hesse()" @@ -403,12 +318,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.659513031Z", - "start_time": "2023-10-08T14:12:45.542576109Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result_simultaneous.params)" @@ -426,12 +336,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.464100818Z", - "start_time": "2023-10-08T14:12:45.600070985Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Sets the values of the parameters to the result of the simultaneous fit\n", @@ -490,12 +395,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.464550806Z", - "start_time": "2023-10-08T14:12:46.460335339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result_simultaneous.params[sig_yield])" @@ -516,12 +416,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.586385288Z", - "start_time": "2023-10-08T14:12:46.464048456Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests.parameters import POI\n", @@ -569,12 +464,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.641308781Z", - "start_time": "2023-10-08T14:12:46.526110396Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests.calculators import AsymptoticCalculator\n", @@ -603,12 +493,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:48.579180062Z", - "start_time": "2023-10-08T14:12:46.612163566Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests import Discovery\n", @@ -631,12 +516,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:50.693800215Z", - "start_time": "2023-10-08T14:12:48.579783616Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Sets the values of the parameters to the result of the simultaneous fit\n", @@ -653,12 +533,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:50.732683239Z", - "start_time": "2023-10-08T14:12:50.695963818Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Samples with sig_yield = 10. Since the model is extended the number of\n", @@ -669,12 +544,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:52.232994100Z", - "start_time": "2023-10-08T14:12:50.720966109Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "calculator_low_sig = AsymptoticCalculator(input=nll_simultaneous_low_sig, minimizer=minimizer)\n", @@ -711,12 +581,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.526640196Z", - "start_time": "2023-10-08T14:12:52.228528490Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests import UpperLimit\n", @@ -734,12 +599,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527076883Z", - "start_time": "2023-10-08T14:13:21.922021692Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from utils import plotlimit\n", @@ -765,12 +625,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527316344Z", - "start_time": "2023-10-08T14:13:21.952539698Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Signal distributions.\n", @@ -814,12 +669,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527536306Z", - "start_time": "2023-10-08T14:13:21.953046059Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Builds the loss.\n", @@ -837,24 +687,14 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527755210Z", - "start_time": "2023-10-08T14:13:21.953198082Z" - } - }, + "metadata": {}, "outputs": [], "source": [] }, { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527995719Z", - "start_time": "2023-10-08T14:13:21.953302534Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Visualization of the result.\n", @@ -887,13 +727,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "scrolled": true, - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.528208655Z", - "start_time": "2023-10-08T14:13:21.996067945Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.splot import compute_sweights\n", @@ -906,12 +740,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.528416949Z", - "start_time": "2023-10-08T14:13:21.996171347Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(\"Sum of signal sWeights: \", np.sum(weights[reso_sig_yield]))\n", @@ -928,12 +757,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.295792064Z", - "start_time": "2023-10-08T14:13:21.996253272Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "fig, axs = plt.subplots(1, 2, figsize=(16, 6))\n", @@ -965,12 +789,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.304003426Z", - "start_time": "2023-10-08T14:13:23.022384744Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(f\"Correlation between m and t: {np.corrcoef(np_m_sw, np_t_sw)[0, 1]}\")" @@ -986,12 +805,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.310003803Z", - "start_time": "2023-10-08T14:13:23.049967479Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "plt.hist(np_m_sw, bins=100, range=(5000, 6000), weights=weights[reso_sig_yield]);" @@ -1000,12 +814,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.310221257Z", - "start_time": "2023-10-08T14:13:23.269437261Z" - } - }, + "metadata": {}, "outputs": [], "source": [] } diff --git a/_website/tutorials/guides/custom_models.ipynb b/_website/tutorials/guides/custom_models.ipynb index 13b63cc..ea9adfc 100644 --- a/_website/tutorials/guides/custom_models.ipynb +++ b/_website/tutorials/guides/custom_models.ipynb @@ -812,8 +812,7 @@ "metadata": { "pycharm": { "name": "#%%\n" - }, - "scrolled": true + } }, "outputs": [], "source": [ diff --git a/_website/tutorials/introduction/Introduction.ipynb b/_website/tutorials/introduction/Introduction.ipynb index 01bb5e0..4e9825c 100644 --- a/_website/tutorials/introduction/Introduction.ipynb +++ b/_website/tutorials/introduction/Introduction.ipynb @@ -23,10 +23,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.636694151Z", - "start_time": "2023-10-08T17:15:37.536133866Z" } }, "outputs": [], @@ -71,10 +67,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682349729Z", - "start_time": "2023-10-08T17:15:37.583908975Z" } }, "outputs": [], @@ -98,10 +90,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682563793Z", - "start_time": "2023-10-08T17:15:37.609556121Z" } }, "outputs": [], @@ -132,10 +120,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682911844Z", - "start_time": "2023-10-08T17:15:37.673908926Z" } }, "outputs": [], @@ -149,10 +133,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.684855706Z", - "start_time": "2023-10-08T17:15:37.691273375Z" } }, "outputs": [], @@ -163,17 +143,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "data_normal[\"obs1\"] # indexing Pandas DataFrame style" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.685089150Z", - "start_time": "2023-10-08T17:15:37.736111664Z" - } - } + ] }, { "cell_type": "markdown", @@ -208,10 +182,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.685182436Z", - "start_time": "2023-10-08T17:15:37.736241279Z" } }, "outputs": [], @@ -233,10 +203,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.726475557Z", - "start_time": "2023-10-08T17:15:37.736327589Z" } }, "outputs": [], @@ -257,10 +223,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.726856779Z", - "start_time": "2023-10-08T17:15:37.780136375Z" } }, "outputs": [], @@ -274,10 +236,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727088035Z", - "start_time": "2023-10-08T17:15:37.780277972Z" } }, "outputs": [], @@ -291,10 +249,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727292498Z", - "start_time": "2023-10-08T17:15:37.780373168Z" } }, "outputs": [], @@ -308,10 +262,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727487450Z", - "start_time": "2023-10-08T17:15:37.780461288Z" } }, "outputs": [], @@ -340,10 +290,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727688282Z", - "start_time": "2023-10-08T17:15:37.780558697Z" } }, "outputs": [], @@ -369,10 +315,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727878550Z", - "start_time": "2023-10-08T17:15:37.780690773Z" } }, "outputs": [], @@ -393,10 +335,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729148926Z", - "start_time": "2023-10-08T17:15:37.780790606Z" } }, "outputs": [], @@ -425,10 +363,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729364375Z", - "start_time": "2023-10-08T17:15:37.828264635Z" } }, "outputs": [], @@ -454,10 +388,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729567436Z", - "start_time": "2023-10-08T17:15:37.828503516Z" } }, "outputs": [], @@ -478,10 +408,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730103870Z", - "start_time": "2023-10-08T17:15:37.828682867Z" } }, "outputs": [], @@ -496,10 +422,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730368487Z", - "start_time": "2023-10-08T17:15:37.957496438Z" } }, "outputs": [], @@ -514,10 +436,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730561061Z", - "start_time": "2023-10-08T17:15:37.966467954Z" } }, "outputs": [], @@ -531,10 +449,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730750018Z", - "start_time": "2023-10-08T17:15:38.008116093Z" } }, "outputs": [], @@ -555,10 +469,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730946329Z", - "start_time": "2023-10-08T17:15:38.008306355Z" } }, "outputs": [], @@ -589,10 +499,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731035724Z", - "start_time": "2023-10-08T17:15:38.052137315Z" } }, "outputs": [], @@ -622,10 +528,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731228982Z", - "start_time": "2023-10-08T17:15:38.052345119Z" } }, "outputs": [], @@ -655,10 +557,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731501448Z", - "start_time": "2023-10-08T17:15:38.296729314Z" } }, "outputs": [], @@ -672,10 +570,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731795511Z", - "start_time": "2023-10-08T17:15:38.340203425Z" } }, "outputs": [], @@ -708,10 +602,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731883367Z", - "start_time": "2023-10-08T17:15:38.340549081Z" } }, "outputs": [], @@ -725,10 +615,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.733373977Z", - "start_time": "2023-10-08T17:15:38.340774243Z" } }, "outputs": [], @@ -748,10 +634,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.733532683Z", - "start_time": "2023-10-08T17:15:38.384046326Z" } }, "outputs": [], @@ -768,10 +650,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734088160Z", - "start_time": "2023-10-08T17:15:38.384157995Z" } }, "outputs": [], @@ -802,10 +680,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734212206Z", - "start_time": "2023-10-08T17:15:38.471708903Z" } }, "outputs": [], @@ -828,10 +702,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734829926Z", - "start_time": "2023-10-08T17:15:38.512454935Z" } }, "outputs": [], @@ -856,10 +726,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.722926595Z", - "start_time": "2023-10-08T17:15:38.512576622Z" } }, "outputs": [], @@ -874,10 +740,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.736035249Z", - "start_time": "2023-10-08T17:15:41.364109617Z" } }, "outputs": [], @@ -898,10 +760,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.736677504Z", - "start_time": "2023-10-08T17:15:41.883747617Z" } }, "outputs": [], @@ -918,10 +776,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.739980258Z", - "start_time": "2023-10-08T17:15:41.924205524Z" } }, "outputs": [], @@ -942,10 +796,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.740945641Z", - "start_time": "2023-10-08T17:15:42.647316864Z" } }, "outputs": [], @@ -979,10 +829,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.747872924Z", - "start_time": "2023-10-08T17:15:42.688139110Z" } }, "outputs": [], @@ -1004,10 +850,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.754351968Z", - "start_time": "2023-10-08T17:15:42.688297371Z" } }, "outputs": [], @@ -1030,10 +872,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.754601526Z", - "start_time": "2023-10-08T17:15:42.732214595Z" } }, "outputs": [], @@ -1056,10 +894,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.318736855Z", - "start_time": "2023-10-08T17:15:42.732546622Z" } }, "outputs": [], @@ -1080,10 +914,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.338989564Z", - "start_time": "2023-10-08T17:15:42.922694285Z" } }, "outputs": [], @@ -1109,17 +939,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "nll_gauss.gradient()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.403485053Z", - "start_time": "2023-10-08T17:15:42.964190028Z" - } - } + ] }, { "cell_type": "markdown", @@ -1134,10 +958,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.403748729Z", - "start_time": "2023-10-08T17:15:43.259420673Z" } }, "outputs": [], @@ -1151,10 +971,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.404042342Z", - "start_time": "2023-10-08T17:15:43.262904350Z" } }, "outputs": [], @@ -1168,10 +984,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.404245757Z", - "start_time": "2023-10-08T17:15:43.270774380Z" } }, "outputs": [], @@ -1192,10 +1004,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.467071652Z", - "start_time": "2023-10-08T17:15:43.276188745Z" } }, "outputs": [], @@ -1218,10 +1026,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.255201842Z", - "start_time": "2023-10-08T17:15:43.324121091Z" } }, "outputs": [], @@ -1235,10 +1039,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.269708841Z", - "start_time": "2023-10-08T17:15:44.255561968Z" } }, "outputs": [], @@ -1270,10 +1070,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.441186596Z", - "start_time": "2023-10-08T17:15:44.266765379Z" } }, "outputs": [], @@ -1301,10 +1097,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.593736903Z", - "start_time": "2023-10-08T17:15:44.312354018Z" } }, "outputs": [], @@ -1318,10 +1110,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.594082520Z", - "start_time": "2023-10-08T17:15:44.312713371Z" } }, "outputs": [], @@ -1357,10 +1145,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:05.262567595Z", - "start_time": "2023-10-08T17:15:44.313007308Z" } }, "outputs": [], @@ -1377,10 +1161,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:18.826677051Z", - "start_time": "2023-10-08T17:16:05.259597602Z" } }, "outputs": [], @@ -1394,10 +1174,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.550060481Z", - "start_time": "2023-10-08T17:16:18.860126963Z" } }, "outputs": [], @@ -1422,10 +1198,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.737141269Z", - "start_time": "2023-10-08T17:16:19.545922952Z" } }, "outputs": [], @@ -1446,10 +1218,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.795574574Z", - "start_time": "2023-10-08T17:16:19.620221600Z" } }, "outputs": [], @@ -1470,10 +1238,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.795979639Z", - "start_time": "2023-10-08T17:16:19.620502669Z" } }, "outputs": [], @@ -1499,10 +1263,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.796351271Z", - "start_time": "2023-10-08T17:16:19.620668395Z" } }, "outputs": [], @@ -1523,10 +1283,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.796940958Z", - "start_time": "2023-10-08T17:16:19.664115753Z" } }, "outputs": [], @@ -1557,10 +1313,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:22.917875149Z", - "start_time": "2023-10-08T17:16:19.664407964Z" } }, "outputs": [], @@ -1574,10 +1326,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:23.126314851Z", - "start_time": "2023-10-08T17:16:22.912844003Z" } }, "outputs": [], @@ -1599,10 +1347,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:23.211861277Z", - "start_time": "2023-10-08T17:16:22.956836830Z" } }, "outputs": [], @@ -1616,10 +1360,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:39.228968594Z", - "start_time": "2023-10-08T17:16:22.957584608Z" } }, "outputs": [], @@ -1634,10 +1374,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.714718057Z", - "start_time": "2023-10-08T17:16:39.212431433Z" } }, "outputs": [], @@ -1651,10 +1387,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.742713838Z", - "start_time": "2023-10-08T17:16:54.710506300Z" } }, "outputs": [], @@ -1668,10 +1400,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.807369644Z", - "start_time": "2023-10-08T17:16:54.717292342Z" } }, "outputs": [], @@ -1701,10 +1429,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.807832126Z", - "start_time": "2023-10-08T17:16:54.784181140Z" } }, "outputs": [], @@ -1714,6 +1438,7 @@ }, { "cell_type": "markdown", + "metadata": {}, "source": [ "### Bonus: serialization\n", "\n", @@ -1721,55 +1446,34 @@ "zfit aims to follow the [HS3](https://github.com/hep-statistics-serialization-standard/hep-statistics-serialization-standard) standard, which is currently in development.\n", "\n", "[**Extended tutorial on serialization**](https://zfit-tutorials.readthedocs.io/en/latest/tutorials/components/90%20-%20Serialization%20basics.html)" - ], - "metadata": { - "collapsed": false - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "model.to_dict()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.021241104Z", - "start_time": "2023-10-08T17:16:54.784360268Z" - } - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "gauss.to_yaml()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.021731517Z", - "start_time": "2023-10-08T17:16:54.828155812Z" - } - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.dumps(nll)" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.188387556Z", - "start_time": "2023-10-08T17:16:54.830241172Z" - } - } + ] }, { "cell_type": "markdown", @@ -1802,10 +1506,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.480434379Z", - "start_time": "2023-10-08T17:16:55.028233121Z" } }, "outputs": [], @@ -1821,10 +1521,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.493353698Z", - "start_time": "2023-10-08T17:16:55.073790994Z" } }, "outputs": [], @@ -1838,10 +1534,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.495115786Z", - "start_time": "2023-10-08T17:16:55.088632340Z" } }, "outputs": [], @@ -1858,10 +1550,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.495258931Z", - "start_time": "2023-10-08T17:16:55.132144278Z" } }, "outputs": [], @@ -1875,10 +1563,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.041054025Z", - "start_time": "2023-10-08T17:16:55.132315074Z" } }, "outputs": [], @@ -1892,10 +1576,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.188325064Z", - "start_time": "2023-10-08T17:17:44.014275211Z" } }, "outputs": [], @@ -1916,12 +1596,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.188463755Z", - "start_time": "2023-10-08T17:17:44.145661353Z" - } - }, + "metadata": {}, "outputs": [], "source": [] } diff --git a/components/20 - Composite Models.ipynb b/components/20 - Composite Models.ipynb index 8c289c1..761f3d5 100644 --- a/components/20 - Composite Models.ipynb +++ b/components/20 - Composite Models.ipynb @@ -159,12 +159,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T16:13:03.168140846Z", - "start_time": "2023-10-08T16:13:02.852036292Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "extended_gauss_method = gauss3.create_extended(yield1)" @@ -173,13 +168,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "gauss3_ext = zfit.pdf.Gauss(obs=obs2, mu=mu3, sigma=sigma3, extended=yield1)" - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/components/60 - Custom PDF.ipynb b/components/60 - Custom PDF.ipynb index f70ebec..8c5c051 100644 --- a/components/60 - Custom PDF.ipynb +++ b/components/60 - Custom PDF.ipynb @@ -172,12 +172,10 @@ }, { "cell_type": "markdown", + "metadata": {}, "source": [ "More advanced custom PDFs are introduced in the guide on [custom PDFs](custom_pdfs.ipynb)." - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/components/90 - Serialization basics.ipynb b/components/90 - Serialization basics.ipynb index a8dbaff..18365e0 100644 --- a/components/90 - Serialization basics.ipynb +++ b/components/90 - Serialization basics.ipynb @@ -19,10 +19,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.279440915Z", - "start_time": "2023-07-04T09:13:44.218982607Z" - }, "jupyter": { "outputs_hidden": false } @@ -46,10 +42,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.344315600Z", - "start_time": "2023-07-04T09:13:44.224966703Z" - }, "jupyter": { "outputs_hidden": false } @@ -66,10 +58,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.626719682Z", - "start_time": "2023-07-04T09:13:44.314016788Z" - }, "jupyter": { "outputs_hidden": false } @@ -84,10 +72,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:44.630490029Z", - "start_time": "2023-07-04T09:13:44.628116302Z" - }, "jupyter": { "outputs_hidden": false } @@ -101,10 +85,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.078062754Z", - "start_time": "2023-07-04T09:13:44.634012974Z" - }, "jupyter": { "outputs_hidden": false } @@ -125,10 +105,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.081724535Z", - "start_time": "2023-07-04T09:13:45.079081658Z" - }, "jupyter": { "outputs_hidden": false } @@ -143,10 +119,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.089182199Z", - "start_time": "2023-07-04T09:13:45.084547906Z" - }, "jupyter": { "outputs_hidden": false } @@ -160,10 +132,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.286143190Z", - "start_time": "2023-07-04T09:13:45.089906166Z" - }, "jupyter": { "outputs_hidden": false } @@ -180,10 +148,6 @@ "cell_type": "code", "execution_count": null, "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.286381522Z", - "start_time": "2023-07-04T09:13:45.110205375Z" - }, "jupyter": { "outputs_hidden": false } @@ -207,12 +171,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.287047511Z", - "start_time": "2023-07-04T09:13:45.151818465Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "model.to_dict()" @@ -221,12 +180,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.287692092Z", - "start_time": "2023-07-04T09:13:45.195475042Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "mu.to_dict()" @@ -235,12 +189,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288178006Z", - "start_time": "2023-07-04T09:13:45.195679267Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "obs.to_dict()" @@ -258,12 +207,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288744487Z", - "start_time": "2023-07-04T09:13:45.195824685Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "gauss2 = model.from_dict(model.to_dict()) # effectively creates a copy (parameters are shared!)\n", @@ -280,12 +224,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.288945771Z", - "start_time": "2023-07-04T09:13:45.243618137Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "gauss3 = zfit.pdf.Gauss.from_dict(model.to_dict())" @@ -303,12 +242,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.289701922Z", - "start_time": "2023-07-04T09:13:45.243850081Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "sigma.to_json()" @@ -317,12 +251,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.290281402Z", - "start_time": "2023-07-04T09:13:45.244018144Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "sigma.to_yaml()" @@ -340,12 +269,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.294861384Z", - "start_time": "2023-07-04T09:13:45.244174736Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data.to_dict()" @@ -361,12 +285,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.307383710Z", - "start_time": "2023-07-04T09:13:45.287498620Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "try:\n", @@ -385,12 +304,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.507248332Z", - "start_time": "2023-07-04T09:13:45.287858472Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf = data.to_asdf()\n", @@ -413,12 +327,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.554688217Z", - "start_time": "2023-07-04T09:13:45.499563339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf.tree" @@ -427,24 +336,14 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.554984413Z", - "start_time": "2023-07-04T09:13:45.547805565Z" - } - }, + "metadata": {}, "outputs": [], "source": [] }, { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:45.555197569Z", - "start_time": "2023-07-04T09:13:45.548139660Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data_asdf.write_to(\"data.asdf\") # Will create a file in the current directory" @@ -460,12 +359,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:46.272975151Z", - "start_time": "2023-07-04T09:13:45.548407961Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "!head -25 data.asdf" @@ -474,12 +368,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.001598595Z", - "start_time": "2023-07-04T09:13:46.251157486Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "!wc -l data.asdf # the file is about 471 lines long, filled with binary" @@ -495,12 +384,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.064629808Z", - "start_time": "2023-07-04T09:13:47.005462375Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "import asdf\n", @@ -513,12 +397,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.093193817Z", - "start_time": "2023-07-04T09:13:47.067703370Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "data.value()" @@ -527,12 +406,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.094131819Z", - "start_time": "2023-07-04T09:13:47.082251988Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# cleanup of the file\n", @@ -560,12 +434,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.160512923Z", - "start_time": "2023-07-04T09:13:47.087043035Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.dumps(model)" @@ -574,12 +443,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.172729691Z", - "start_time": "2023-07-04T09:13:47.127529113Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3obj = zfit.hs3.loads(zfit.hs3.dumps(model))" @@ -588,12 +452,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.173480212Z", - "start_time": "2023-07-04T09:13:47.172020303Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "list(hs3obj['distributions'].values())" @@ -611,12 +470,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.319939293Z", - "start_time": "2023-07-04T09:13:47.172476842Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped = zfit.hs3.dumps(model)\n", @@ -626,12 +480,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.511521384Z", - "start_time": "2023-07-04T09:13:47.308345461Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped = zfit.hs3.dumps(loss)\n", @@ -641,12 +490,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.543604166Z", - "start_time": "2023-07-04T09:13:47.535423644Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "hs3dumped" @@ -655,12 +499,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-07-04T09:13:47.672205748Z", - "start_time": "2023-07-04T09:13:47.535685300Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.loads(hs3dumped)" diff --git a/guides/constraints_simultaneous_fit_discovery_splot.ipynb b/guides/constraints_simultaneous_fit_discovery_splot.ipynb index 6228cf1..f53672f 100644 --- a/guides/constraints_simultaneous_fit_discovery_splot.ipynb +++ b/guides/constraints_simultaneous_fit_discovery_splot.ipynb @@ -27,12 +27,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489215542Z", - "start_time": "2023-10-08T14:12:39.756038115Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "import hepunits as u\n", @@ -49,12 +44,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489484263Z", - "start_time": "2023-10-08T14:12:39.843646064Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "mu_true = lp.B_plus.mass * u.MeV\n", @@ -68,12 +58,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489628044Z", - "start_time": "2023-10-08T14:12:39.888112598Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# create some data\n", @@ -85,12 +70,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.489915684Z", - "start_time": "2023-10-08T14:12:39.888213619Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Firstly, the observable and its range is defined\n", @@ -100,12 +80,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.490043904Z", - "start_time": "2023-10-08T14:12:39.936032491Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# load data into zfit\n", @@ -115,12 +90,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.505837597Z", - "start_time": "2023-10-08T14:12:39.981346354Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Parameters are specified: (name (unique), initial, lower, upper) whereas lower, upper are optional\n", @@ -145,12 +115,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:40.506011519Z", - "start_time": "2023-10-08T14:12:40.028065418Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "constraint = zfit.constraint.GaussianConstraint(mu, observation=5275 * u.MeV, uncertainty=15 * u.MeV)" @@ -159,12 +124,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.005963419Z", - "start_time": "2023-10-08T14:12:40.028138339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "nll = zfit.loss.ExtendedUnbinnedNLL(model, data, constraints=constraint)\n", @@ -176,12 +136,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.052831330Z", - "start_time": "2023-10-08T14:12:41.007823487Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result.params)" @@ -211,12 +166,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.052995596Z", - "start_time": "2023-10-08T14:12:41.052115586Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "n_sig_reso = 40000\n", @@ -226,12 +176,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133459640Z", - "start_time": "2023-10-08T14:12:41.052211792Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# create some data\n", @@ -277,12 +222,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133682724Z", - "start_time": "2023-10-08T14:12:41.100105831Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Firstly, we create a free scaling parameter\n", @@ -302,12 +242,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:41.133773368Z", - "start_time": "2023-10-08T14:12:41.100194140Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "signal_reso = zfit.pdf.Gauss(mu=mu, # the same as for the rare mode\n", @@ -345,12 +280,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:42.214580213Z", - "start_time": "2023-10-08T14:12:41.100235132Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "nll_rare = zfit.loss.ExtendedUnbinnedNLL(model, data)\n", @@ -361,12 +291,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:42.264410782Z", - "start_time": "2023-10-08T14:12:42.221507568Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "extended_sig_reso.get_yield()" @@ -375,12 +300,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.102306848Z", - "start_time": "2023-10-08T14:12:42.264125616Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "result_simultaneous = minimizer.minimize(nll_simultaneous)" @@ -389,12 +309,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.551062544Z", - "start_time": "2023-10-08T14:12:45.073654511Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "result_simultaneous.hesse()" @@ -403,12 +318,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:45.659513031Z", - "start_time": "2023-10-08T14:12:45.542576109Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result_simultaneous.params)" @@ -426,12 +336,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.464100818Z", - "start_time": "2023-10-08T14:12:45.600070985Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Sets the values of the parameters to the result of the simultaneous fit\n", @@ -490,12 +395,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.464550806Z", - "start_time": "2023-10-08T14:12:46.460335339Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(result_simultaneous.params[sig_yield])" @@ -516,12 +416,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.586385288Z", - "start_time": "2023-10-08T14:12:46.464048456Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests.parameters import POI\n", @@ -569,12 +464,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:46.641308781Z", - "start_time": "2023-10-08T14:12:46.526110396Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests.calculators import AsymptoticCalculator\n", @@ -603,12 +493,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:48.579180062Z", - "start_time": "2023-10-08T14:12:46.612163566Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests import Discovery\n", @@ -631,12 +516,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:50.693800215Z", - "start_time": "2023-10-08T14:12:48.579783616Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Sets the values of the parameters to the result of the simultaneous fit\n", @@ -653,12 +533,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:50.732683239Z", - "start_time": "2023-10-08T14:12:50.695963818Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Samples with sig_yield = 10. Since the model is extended the number of\n", @@ -669,12 +544,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:12:52.232994100Z", - "start_time": "2023-10-08T14:12:50.720966109Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "calculator_low_sig = AsymptoticCalculator(input=nll_simultaneous_low_sig, minimizer=minimizer)\n", @@ -711,12 +581,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.526640196Z", - "start_time": "2023-10-08T14:12:52.228528490Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.hypotests import UpperLimit\n", @@ -734,12 +599,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527076883Z", - "start_time": "2023-10-08T14:13:21.922021692Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from utils import plotlimit\n", @@ -765,12 +625,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527316344Z", - "start_time": "2023-10-08T14:13:21.952539698Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Signal distributions.\n", @@ -814,12 +669,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527536306Z", - "start_time": "2023-10-08T14:13:21.953046059Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Builds the loss.\n", @@ -837,24 +687,14 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527755210Z", - "start_time": "2023-10-08T14:13:21.953198082Z" - } - }, + "metadata": {}, "outputs": [], "source": [] }, { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.527995719Z", - "start_time": "2023-10-08T14:13:21.953302534Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "# Visualization of the result.\n", @@ -887,13 +727,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "scrolled": true, - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.528208655Z", - "start_time": "2023-10-08T14:13:21.996067945Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "from hepstats.splot import compute_sweights\n", @@ -906,12 +740,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:22.528416949Z", - "start_time": "2023-10-08T14:13:21.996171347Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(\"Sum of signal sWeights: \", np.sum(weights[reso_sig_yield]))\n", @@ -928,12 +757,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.295792064Z", - "start_time": "2023-10-08T14:13:21.996253272Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "fig, axs = plt.subplots(1, 2, figsize=(16, 6))\n", @@ -965,12 +789,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.304003426Z", - "start_time": "2023-10-08T14:13:23.022384744Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "print(f\"Correlation between m and t: {np.corrcoef(np_m_sw, np_t_sw)[0, 1]}\")" @@ -986,12 +805,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.310003803Z", - "start_time": "2023-10-08T14:13:23.049967479Z" - } - }, + "metadata": {}, "outputs": [], "source": [ "plt.hist(np_m_sw, bins=100, range=(5000, 6000), weights=weights[reso_sig_yield]);" @@ -1000,12 +814,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T14:13:23.310221257Z", - "start_time": "2023-10-08T14:13:23.269437261Z" - } - }, + "metadata": {}, "outputs": [], "source": [] } diff --git a/guides/custom_models.ipynb b/guides/custom_models.ipynb index 13b63cc..ea9adfc 100644 --- a/guides/custom_models.ipynb +++ b/guides/custom_models.ipynb @@ -812,8 +812,7 @@ "metadata": { "pycharm": { "name": "#%%\n" - }, - "scrolled": true + } }, "outputs": [], "source": [ diff --git a/introduction/Introduction.ipynb b/introduction/Introduction.ipynb index 01bb5e0..4e9825c 100644 --- a/introduction/Introduction.ipynb +++ b/introduction/Introduction.ipynb @@ -23,10 +23,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.636694151Z", - "start_time": "2023-10-08T17:15:37.536133866Z" } }, "outputs": [], @@ -71,10 +67,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682349729Z", - "start_time": "2023-10-08T17:15:37.583908975Z" } }, "outputs": [], @@ -98,10 +90,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682563793Z", - "start_time": "2023-10-08T17:15:37.609556121Z" } }, "outputs": [], @@ -132,10 +120,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.682911844Z", - "start_time": "2023-10-08T17:15:37.673908926Z" } }, "outputs": [], @@ -149,10 +133,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.684855706Z", - "start_time": "2023-10-08T17:15:37.691273375Z" } }, "outputs": [], @@ -163,17 +143,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "data_normal[\"obs1\"] # indexing Pandas DataFrame style" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.685089150Z", - "start_time": "2023-10-08T17:15:37.736111664Z" - } - } + ] }, { "cell_type": "markdown", @@ -208,10 +182,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.685182436Z", - "start_time": "2023-10-08T17:15:37.736241279Z" } }, "outputs": [], @@ -233,10 +203,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.726475557Z", - "start_time": "2023-10-08T17:15:37.736327589Z" } }, "outputs": [], @@ -257,10 +223,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.726856779Z", - "start_time": "2023-10-08T17:15:37.780136375Z" } }, "outputs": [], @@ -274,10 +236,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727088035Z", - "start_time": "2023-10-08T17:15:37.780277972Z" } }, "outputs": [], @@ -291,10 +249,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727292498Z", - "start_time": "2023-10-08T17:15:37.780373168Z" } }, "outputs": [], @@ -308,10 +262,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727487450Z", - "start_time": "2023-10-08T17:15:37.780461288Z" } }, "outputs": [], @@ -340,10 +290,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727688282Z", - "start_time": "2023-10-08T17:15:37.780558697Z" } }, "outputs": [], @@ -369,10 +315,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.727878550Z", - "start_time": "2023-10-08T17:15:37.780690773Z" } }, "outputs": [], @@ -393,10 +335,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729148926Z", - "start_time": "2023-10-08T17:15:37.780790606Z" } }, "outputs": [], @@ -425,10 +363,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729364375Z", - "start_time": "2023-10-08T17:15:37.828264635Z" } }, "outputs": [], @@ -454,10 +388,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.729567436Z", - "start_time": "2023-10-08T17:15:37.828503516Z" } }, "outputs": [], @@ -478,10 +408,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730103870Z", - "start_time": "2023-10-08T17:15:37.828682867Z" } }, "outputs": [], @@ -496,10 +422,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730368487Z", - "start_time": "2023-10-08T17:15:37.957496438Z" } }, "outputs": [], @@ -514,10 +436,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730561061Z", - "start_time": "2023-10-08T17:15:37.966467954Z" } }, "outputs": [], @@ -531,10 +449,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730750018Z", - "start_time": "2023-10-08T17:15:38.008116093Z" } }, "outputs": [], @@ -555,10 +469,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.730946329Z", - "start_time": "2023-10-08T17:15:38.008306355Z" } }, "outputs": [], @@ -589,10 +499,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731035724Z", - "start_time": "2023-10-08T17:15:38.052137315Z" } }, "outputs": [], @@ -622,10 +528,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731228982Z", - "start_time": "2023-10-08T17:15:38.052345119Z" } }, "outputs": [], @@ -655,10 +557,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731501448Z", - "start_time": "2023-10-08T17:15:38.296729314Z" } }, "outputs": [], @@ -672,10 +570,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731795511Z", - "start_time": "2023-10-08T17:15:38.340203425Z" } }, "outputs": [], @@ -708,10 +602,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.731883367Z", - "start_time": "2023-10-08T17:15:38.340549081Z" } }, "outputs": [], @@ -725,10 +615,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.733373977Z", - "start_time": "2023-10-08T17:15:38.340774243Z" } }, "outputs": [], @@ -748,10 +634,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.733532683Z", - "start_time": "2023-10-08T17:15:38.384046326Z" } }, "outputs": [], @@ -768,10 +650,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734088160Z", - "start_time": "2023-10-08T17:15:38.384157995Z" } }, "outputs": [], @@ -802,10 +680,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734212206Z", - "start_time": "2023-10-08T17:15:38.471708903Z" } }, "outputs": [], @@ -828,10 +702,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:40.734829926Z", - "start_time": "2023-10-08T17:15:38.512454935Z" } }, "outputs": [], @@ -856,10 +726,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.722926595Z", - "start_time": "2023-10-08T17:15:38.512576622Z" } }, "outputs": [], @@ -874,10 +740,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.736035249Z", - "start_time": "2023-10-08T17:15:41.364109617Z" } }, "outputs": [], @@ -898,10 +760,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.736677504Z", - "start_time": "2023-10-08T17:15:41.883747617Z" } }, "outputs": [], @@ -918,10 +776,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.739980258Z", - "start_time": "2023-10-08T17:15:41.924205524Z" } }, "outputs": [], @@ -942,10 +796,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.740945641Z", - "start_time": "2023-10-08T17:15:42.647316864Z" } }, "outputs": [], @@ -979,10 +829,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.747872924Z", - "start_time": "2023-10-08T17:15:42.688139110Z" } }, "outputs": [], @@ -1004,10 +850,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.754351968Z", - "start_time": "2023-10-08T17:15:42.688297371Z" } }, "outputs": [], @@ -1030,10 +872,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:42.754601526Z", - "start_time": "2023-10-08T17:15:42.732214595Z" } }, "outputs": [], @@ -1056,10 +894,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.318736855Z", - "start_time": "2023-10-08T17:15:42.732546622Z" } }, "outputs": [], @@ -1080,10 +914,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.338989564Z", - "start_time": "2023-10-08T17:15:42.922694285Z" } }, "outputs": [], @@ -1109,17 +939,11 @@ { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "nll_gauss.gradient()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.403485053Z", - "start_time": "2023-10-08T17:15:42.964190028Z" - } - } + ] }, { "cell_type": "markdown", @@ -1134,10 +958,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.403748729Z", - "start_time": "2023-10-08T17:15:43.259420673Z" } }, "outputs": [], @@ -1151,10 +971,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.404042342Z", - "start_time": "2023-10-08T17:15:43.262904350Z" } }, "outputs": [], @@ -1168,10 +984,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.404245757Z", - "start_time": "2023-10-08T17:15:43.270774380Z" } }, "outputs": [], @@ -1192,10 +1004,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:43.467071652Z", - "start_time": "2023-10-08T17:15:43.276188745Z" } }, "outputs": [], @@ -1218,10 +1026,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.255201842Z", - "start_time": "2023-10-08T17:15:43.324121091Z" } }, "outputs": [], @@ -1235,10 +1039,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.269708841Z", - "start_time": "2023-10-08T17:15:44.255561968Z" } }, "outputs": [], @@ -1270,10 +1070,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.441186596Z", - "start_time": "2023-10-08T17:15:44.266765379Z" } }, "outputs": [], @@ -1301,10 +1097,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.593736903Z", - "start_time": "2023-10-08T17:15:44.312354018Z" } }, "outputs": [], @@ -1318,10 +1110,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:15:44.594082520Z", - "start_time": "2023-10-08T17:15:44.312713371Z" } }, "outputs": [], @@ -1357,10 +1145,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:05.262567595Z", - "start_time": "2023-10-08T17:15:44.313007308Z" } }, "outputs": [], @@ -1377,10 +1161,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:18.826677051Z", - "start_time": "2023-10-08T17:16:05.259597602Z" } }, "outputs": [], @@ -1394,10 +1174,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.550060481Z", - "start_time": "2023-10-08T17:16:18.860126963Z" } }, "outputs": [], @@ -1422,10 +1198,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.737141269Z", - "start_time": "2023-10-08T17:16:19.545922952Z" } }, "outputs": [], @@ -1446,10 +1218,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.795574574Z", - "start_time": "2023-10-08T17:16:19.620221600Z" } }, "outputs": [], @@ -1470,10 +1238,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.795979639Z", - "start_time": "2023-10-08T17:16:19.620502669Z" } }, "outputs": [], @@ -1499,10 +1263,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.796351271Z", - "start_time": "2023-10-08T17:16:19.620668395Z" } }, "outputs": [], @@ -1523,10 +1283,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:19.796940958Z", - "start_time": "2023-10-08T17:16:19.664115753Z" } }, "outputs": [], @@ -1557,10 +1313,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:22.917875149Z", - "start_time": "2023-10-08T17:16:19.664407964Z" } }, "outputs": [], @@ -1574,10 +1326,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:23.126314851Z", - "start_time": "2023-10-08T17:16:22.912844003Z" } }, "outputs": [], @@ -1599,10 +1347,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:23.211861277Z", - "start_time": "2023-10-08T17:16:22.956836830Z" } }, "outputs": [], @@ -1616,10 +1360,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:39.228968594Z", - "start_time": "2023-10-08T17:16:22.957584608Z" } }, "outputs": [], @@ -1634,10 +1374,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.714718057Z", - "start_time": "2023-10-08T17:16:39.212431433Z" } }, "outputs": [], @@ -1651,10 +1387,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.742713838Z", - "start_time": "2023-10-08T17:16:54.710506300Z" } }, "outputs": [], @@ -1668,10 +1400,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.807369644Z", - "start_time": "2023-10-08T17:16:54.717292342Z" } }, "outputs": [], @@ -1701,10 +1429,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:54.807832126Z", - "start_time": "2023-10-08T17:16:54.784181140Z" } }, "outputs": [], @@ -1714,6 +1438,7 @@ }, { "cell_type": "markdown", + "metadata": {}, "source": [ "### Bonus: serialization\n", "\n", @@ -1721,55 +1446,34 @@ "zfit aims to follow the [HS3](https://github.com/hep-statistics-serialization-standard/hep-statistics-serialization-standard) standard, which is currently in development.\n", "\n", "[**Extended tutorial on serialization**](https://zfit-tutorials.readthedocs.io/en/latest/tutorials/components/90%20-%20Serialization%20basics.html)" - ], - "metadata": { - "collapsed": false - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "model.to_dict()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.021241104Z", - "start_time": "2023-10-08T17:16:54.784360268Z" - } - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "gauss.to_yaml()" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.021731517Z", - "start_time": "2023-10-08T17:16:54.828155812Z" - } - } + ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], "source": [ "zfit.hs3.dumps(nll)" - ], - "metadata": { - "collapsed": false, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.188387556Z", - "start_time": "2023-10-08T17:16:54.830241172Z" - } - } + ] }, { "cell_type": "markdown", @@ -1802,10 +1506,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.480434379Z", - "start_time": "2023-10-08T17:16:55.028233121Z" } }, "outputs": [], @@ -1821,10 +1521,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.493353698Z", - "start_time": "2023-10-08T17:16:55.073790994Z" } }, "outputs": [], @@ -1838,10 +1534,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.495115786Z", - "start_time": "2023-10-08T17:16:55.088632340Z" } }, "outputs": [], @@ -1858,10 +1550,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:16:55.495258931Z", - "start_time": "2023-10-08T17:16:55.132144278Z" } }, "outputs": [], @@ -1875,10 +1563,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.041054025Z", - "start_time": "2023-10-08T17:16:55.132315074Z" } }, "outputs": [], @@ -1892,10 +1576,6 @@ "metadata": { "pycharm": { "is_executing": true - }, - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.188325064Z", - "start_time": "2023-10-08T17:17:44.014275211Z" } }, "outputs": [], @@ -1916,12 +1596,7 @@ { "cell_type": "code", "execution_count": null, - "metadata": { - "ExecuteTime": { - "end_time": "2023-10-08T17:17:44.188463755Z", - "start_time": "2023-10-08T17:17:44.145661353Z" - } - }, + "metadata": {}, "outputs": [], "source": [] }