Update nb

This commit is contained in:
rstiskalek 2023-04-01 07:56:52 +01:00
parent 8fc4e614e3
commit f26cf087ab

View file

@ -6,8 +6,8 @@
"id": "5a38ed25",
"metadata": {
"ExecuteTime": {
"end_time": "2023-04-01T06:10:36.618752Z",
"start_time": "2023-04-01T06:10:10.251616Z"
"end_time": "2023-04-01T06:20:33.195162Z",
"start_time": "2023-04-01T06:20:29.474122Z"
},
"scrolled": true
},
@ -43,12 +43,12 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 2,
"id": "4218b673",
"metadata": {
"ExecuteTime": {
"end_time": "2023-04-01T06:10:44.171672Z",
"start_time": "2023-04-01T06:10:42.109733Z"
"end_time": "2023-04-01T06:20:35.273662Z",
"start_time": "2023-04-01T06:20:33.196875Z"
}
},
"outputs": [],
@ -58,11 +58,12 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 24,
"id": "5ff7a1b6",
"metadata": {
"ExecuteTime": {
"start_time": "2023-04-01T06:12:15.998Z"
"end_time": "2023-04-01T06:55:34.643955Z",
"start_time": "2023-04-01T06:55:28.334204Z"
}
},
"outputs": [
@ -70,8 +71,7 @@
"name": "stderr",
"output_type": "stream",
"text": [
"\r",
" 0%| | 0/1 [00:00<?, ?it/s]"
"100%|██████████| 1/1 [00:02<00:00, 2.95s/it]\n"
]
}
],
@ -82,61 +82,16 @@
"knncdf = csiborgtools.match.kNN_CDF()\n",
"\n",
"rs, cdf = knncdf(knn, nneighbours=2, Rmax=155 / 0.705, rmin=0.01, rmax=100,\n",
" nsamples=int(1e8), neval=int(1e4), random_state=42, batch_size=int(1e7))"
" nsamples=int(1e6), neval=int(1e4), random_state=42, batch_size=int(1e6))"
]
},
{
"cell_type": "code",
"execution_count": 9,
"id": "2b85c1c6",
"metadata": {
"ExecuteTime": {
"end_time": "2023-04-01T06:11:13.560595Z",
"start_time": "2023-04-01T06:11:12.888821Z"
}
},
"execution_count": null,
"id": "0d5f3d02",
"metadata": {},
"outputs": [],
"source": [
"X = knncdf.rvs_in_sphere(nsamples=int(1e7), R=1.)"
]
},
{
"cell_type": "code",
"execution_count": 10,
"id": "3a80cb5b",
"metadata": {
"ExecuteTime": {
"end_time": "2023-04-01T06:11:15.024753Z",
"start_time": "2023-04-01T06:11:14.973967Z"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Variable Type Data/Info\n",
"------------------------------------------------\n",
"NearestNeighbors ABCMeta <class 'sklearn.neighbors<...>rvised.NearestNeighbors'>\n",
"X ndarray 10000000x3: 30000000 elems, type `float32`, 120000000 bytes (114.44091796875 Mb)\n",
"cat HaloCatalogue <csiborgtools.read.make_c<...>object at 0x7fbbc6073fa0>\n",
"cdf ndarray 2x9999: 19998 elems, type `float32`, 79992 bytes\n",
"csiborgtools module <module 'csiborgtools' fr<...>siborgtools/__init__.py'>\n",
"joblib module <module 'joblib' from '/m<...>ages/joblib/__init__.py'>\n",
"knn NearestNeighbors NearestNeighbors()\n",
"knncdf kNN_CDF <csiborgtools.match.knn.k<...>object at 0x7fbbc68bb5b0>\n",
"matplotlib module <module 'matplotlib' from<...>/matplotlib/__init__.py'>\n",
"np module <module 'numpy' from '/mn<...>kages/numpy/__init__.py'>\n",
"plt module <module 'matplotlib.pyplo<...>es/matplotlib/pyplot.py'>\n",
"rs ndarray 9999: 9999 elems, type `float64`, 79992 bytes\n",
"sys module <module 'sys' (built-in)>\n",
"tqdm type <class 'tqdm.std.tqdm'>\n"
]
}
],
"source": [
"%whos"
]
"source": []
},
{
"cell_type": "code",