├── .gitignore ├── LICENSE ├── README.md ├── Usage examples.ipynb ├── imgs └── results.png └── main.py /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | build/ 12 | develop-eggs/ 13 | dist/ 14 | downloads/ 15 | eggs/ 16 | .eggs/ 17 | lib/ 18 | lib64/ 19 | parts/ 20 | sdist/ 21 | var/ 22 | wheels/ 23 | pip-wheel-metadata/ 24 | share/python-wheels/ 25 | *.egg-info/ 26 | .installed.cfg 27 | *.egg 28 | MANIFEST 29 | 30 | # PyInstaller 31 | # Usually these files are written by a python script from a template 32 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 33 | *.manifest 34 | *.spec 35 | 36 | # Installer logs 37 | pip-log.txt 38 | pip-delete-this-directory.txt 39 | 40 | # Unit test / coverage reports 41 | htmlcov/ 42 | .tox/ 43 | .nox/ 44 | .coverage 45 | .coverage.* 46 | .cache 47 | nosetests.xml 48 | coverage.xml 49 | *.cover 50 | *.py,cover 51 | .hypothesis/ 52 | .pytest_cache/ 53 | 54 | # Translations 55 | *.mo 56 | *.pot 57 | 58 | # Django stuff: 59 | *.log 60 | local_settings.py 61 | db.sqlite3 62 | db.sqlite3-journal 63 | 64 | # Flask stuff: 65 | instance/ 66 | .webassets-cache 67 | 68 | # Scrapy stuff: 69 | .scrapy 70 | 71 | # Sphinx documentation 72 | docs/_build/ 73 | 74 | # PyBuilder 75 | target/ 76 | 77 | # Jupyter Notebook 78 | .ipynb_checkpoints 79 | 80 | # IPython 81 | profile_default/ 82 | ipython_config.py 83 | 84 | # pyenv 85 | .python-version 86 | 87 | # pipenv 88 | # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. 89 | # However, in case of collaboration, if having platform-specific dependencies or dependencies 90 | # having no cross-platform support, pipenv may install dependencies that don't work, or not 91 | # install all needed dependencies. 92 | #Pipfile.lock 93 | 94 | # PEP 582; used by e.g. github.com/David-OConnor/pyflow 95 | __pypackages__/ 96 | 97 | # Celery stuff 98 | celerybeat-schedule 99 | celerybeat.pid 100 | 101 | # SageMath parsed files 102 | *.sage.py 103 | 104 | # Environments 105 | .env 106 | .venv 107 | env/ 108 | venv/ 109 | ENV/ 110 | env.bak/ 111 | venv.bak/ 112 | 113 | # Spyder project settings 114 | .spyderproject 115 | .spyproject 116 | 117 | # Rope project settings 118 | .ropeproject 119 | 120 | # mkdocs documentation 121 | /site 122 | 123 | # mypy 124 | .mypy_cache/ 125 | .dmypy.json 126 | dmypy.json 127 | 128 | # Pyre type checker 129 | .pyre/ 130 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "[]" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright [yyyy] [name of copyright owner] 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # kaggle-kernels-helper 2 | 3 | If you are tired to figure out where is the version of kaggle kernel with the best score - we are here to help you :) 4 | 5 | **Note:** you need to download chromedriver and put it in the local folder near the `main.py` 6 | 7 | ![Results](imgs/results.png) 8 | 9 | To receive this example output: 10 | ``` 11 | python3 main.py https://www.kaggle.com/alexryzhkov/n3-tps-april-21-lightautoml-starter output.csv 12 | ``` 13 | -------------------------------------------------------------------------------- /Usage examples.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "code", 5 | "execution_count": 1, 6 | "metadata": {}, 7 | "outputs": [ 8 | { 9 | "name": "stderr", 10 | "output_type": "stream", 11 | "text": [ 12 | "\r", 13 | "Receiving scores for versions:: 0%| | 0/26 [00:00\n", 59 | "\n", 72 | "\n", 73 | " \n", 74 | " \n", 75 | " \n", 76 | " \n", 77 | " \n", 78 | " \n", 79 | " \n", 80 | " \n", 81 | " \n", 82 | " \n", 83 | " \n", 84 | " \n", 85 | " \n", 86 | " \n", 87 | " \n", 88 | " \n", 89 | " \n", 90 | " \n", 91 | " \n", 92 | " \n", 93 | " \n", 94 | " \n", 95 | " \n", 96 | " \n", 97 | " \n", 98 | " \n", 99 | " \n", 100 | " \n", 101 | " \n", 102 | " \n", 103 | " \n", 104 | " \n", 105 | " \n", 106 | " \n", 107 | " \n", 108 | " \n", 109 | " \n", 110 | " \n", 111 | " \n", 112 | " \n", 113 | " \n", 114 | " \n", 115 | " \n", 116 | " \n", 117 | " \n", 118 | " \n", 119 | " \n", 120 | " \n", 121 | " \n", 122 | " \n", 123 | " \n", 124 | " \n", 125 | " \n", 126 | " \n", 127 | " \n", 128 | " \n", 129 | " \n", 130 | " \n", 131 | " \n", 132 | " \n", 133 | " \n", 134 | " \n", 135 | " \n", 136 | " \n", 137 | " \n", 138 | " \n", 139 | " \n", 140 | " \n", 141 | " \n", 142 | " \n", 143 | " \n", 144 | " \n", 145 | " \n", 146 | " \n", 147 | " \n", 148 | " \n", 149 | " \n", 150 | " \n", 151 | " \n", 152 | " \n", 153 | " \n", 154 | " \n", 155 | " \n", 156 | " \n", 157 | " \n", 158 | " \n", 159 | " \n", 160 | " \n", 161 | " \n", 162 | " \n", 163 | " \n", 164 | " \n", 165 | " \n", 166 | " \n", 167 | " \n", 168 | " \n", 169 | " \n", 170 | " \n", 171 | " \n", 172 | " \n", 173 | " \n", 174 | " \n", 175 | " \n", 176 | " \n", 177 | " \n", 178 | " \n", 179 | " \n", 180 | " \n", 181 | " \n", 182 | " \n", 183 | " \n", 184 | " \n", 185 | " \n", 186 | " \n", 187 | " \n", 188 | " \n", 189 | " \n", 190 | " \n", 191 | " \n", 192 | " \n", 193 | " \n", 194 | " \n", 195 | " \n", 196 | " \n", 197 | " \n", 198 | " \n", 199 | " \n", 200 | " \n", 201 | " \n", 202 | " \n", 203 | " \n", 204 | " \n", 205 | " \n", 206 | " \n", 207 | " \n", 208 | " \n", 209 | " \n", 210 | " \n", 211 | " \n", 212 | " \n", 213 | " \n", 214 | " \n", 215 | " \n", 216 | " \n", 217 | " \n", 218 | " \n", 219 | " \n", 220 | " \n", 221 | " \n", 222 | " \n", 223 | " \n", 224 | " \n", 225 | " \n", 226 | " \n", 227 | " \n", 228 | " \n", 229 | " \n", 230 | " \n", 231 | " \n", 232 | " \n", 233 | " \n", 234 | " \n", 235 | " \n", 236 | " \n", 237 | " \n", 238 | " \n", 239 | " \n", 240 | " \n", 241 | " \n", 242 | " \n", 243 | " \n", 244 | " \n", 245 | " \n", 246 | " \n", 247 | " \n", 248 | " \n", 249 | " \n", 250 | " \n", 251 | " \n", 252 | " \n", 253 | " \n", 254 | " \n", 255 | " \n", 256 | " \n", 257 | " \n", 258 | " \n", 259 | " \n", 260 | " \n", 261 | " \n", 262 | " \n", 263 | " \n", 264 | " \n", 265 | " \n", 266 | " \n", 267 | " \n", 268 | " \n", 269 | " \n", 270 | " \n", 271 | " \n", 272 | " \n", 273 | " \n", 274 | " \n", 275 | " \n", 276 | " \n", 277 | " \n", 278 | " \n", 279 | " \n", 280 | " \n", 281 | " \n", 282 | " \n", 283 | " \n", 284 | " \n", 285 | " \n", 286 | " \n", 287 | " \n", 288 | " \n", 289 | " \n", 290 | " \n", 291 | " \n", 292 | " \n", 293 | " \n", 294 | " \n", 295 | " \n", 296 | " \n", 297 | " \n", 298 | " \n", 299 | " \n", 300 | " \n", 301 | " \n", 302 | " \n", 303 | " \n", 304 | " \n", 305 | " \n", 306 | " \n", 307 | " \n", 308 | " \n", 309 | " \n", 310 | " \n", 311 | " \n", 312 | " \n", 313 | " \n", 314 | " \n", 315 | " \n", 316 | " \n", 317 | " \n", 318 | " \n", 319 | " \n", 320 | " \n", 321 | " \n", 322 | " \n", 323 | " \n", 324 | " \n", 325 | " \n", 326 | " \n", 327 | " \n", 328 | " \n", 329 | " \n", 330 | " \n", 331 | " \n", 332 | " \n", 333 | " \n", 334 | " \n", 335 | " \n", 336 | " \n", 337 | " \n", 338 | " \n", 339 | " \n", 340 | " \n", 341 | " \n", 342 | " \n", 343 | " \n", 344 | " \n", 345 | " \n", 346 | " \n", 347 | "
StatusLinkNameRunDateDurationPublicScorePrivateScore
0OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 26Sat Apr 10 2021 22:45:3719373.40.81149NaN
1OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 25Sat Apr 10 2021 07:19:3121326.70.81125NaN
2OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 24Sat Apr 10 2021 00:54:2115522.10.81137NaN
3OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 23Fri Apr 09 2021 21:23:295990.90.81060NaN
4OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 22Fri Apr 09 2021 16:29:189285.70.80887NaN
5OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 21Fri Apr 09 2021 09:17:5812046.30.80947NaN
6OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 20Fri Apr 09 2021 00:02:4413446.10.80871NaN
7OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 19Thu Apr 08 2021 22:15:045971.70.80782NaN
8OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 18Wed Apr 07 2021 21:51:564235.30.80322NaN
9OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 17Wed Apr 07 2021 09:12:044567.20.80253NaN
10OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 16Wed Apr 07 2021 07:45:564891.3NaNNaN
11OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 15Tue Apr 06 2021 22:57:1513285.60.80237NaN
12OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 14Tue Apr 06 2021 20:57:354164.70.80394NaN
13OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 13Tue Apr 06 2021 19:43:04288.70.80245NaN
14OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 12Tue Apr 06 2021 15:45:217824.30.80007NaN
15OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 11Tue Apr 06 2021 15:05:58253.00.80176NaN
16OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 10Sun Apr 04 2021 17:31:523457.2NaNNaN
17OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 9Sun Apr 04 2021 00:26:1326340.80.79664NaN
18Failed/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 8Sun Apr 04 2021 00:24:478.9NaNNaN
19OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 7Sat Apr 03 2021 16:21:1414235.70.79397NaN
20OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 6Sat Apr 03 2021 11:56:1410736.70.79688NaN
21OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 5Thu Apr 01 2021 17:04:046450.40.79268NaN
22OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 4Thu Apr 01 2021 15:13:293350.50.79837NaN
23OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 3Thu Apr 01 2021 14:06:013218.6NaNNaN
24OK/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 2Thu Apr 01 2021 12:05:333506.00.79058NaN
25Failed/alexryzhkov/n3-tps-april-21-lightautoml-start...Version 1Thu Apr 01 2021 11:59:58295.3NaNNaN
\n", 348 | "" 349 | ], 350 | "text/plain": [ 351 | " Status Link Name \\\n", 352 | "0 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 26 \n", 353 | "1 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 25 \n", 354 | "2 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 24 \n", 355 | "3 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 23 \n", 356 | "4 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 22 \n", 357 | "5 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 21 \n", 358 | "6 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 20 \n", 359 | "7 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 19 \n", 360 | "8 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 18 \n", 361 | "9 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 17 \n", 362 | "10 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 16 \n", 363 | "11 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 15 \n", 364 | "12 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 14 \n", 365 | "13 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 13 \n", 366 | "14 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 12 \n", 367 | "15 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 11 \n", 368 | "16 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 10 \n", 369 | "17 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 9 \n", 370 | "18 Failed /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 8 \n", 371 | "19 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 7 \n", 372 | "20 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 6 \n", 373 | "21 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 5 \n", 374 | "22 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 4 \n", 375 | "23 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 3 \n", 376 | "24 OK /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 2 \n", 377 | "25 Failed /alexryzhkov/n3-tps-april-21-lightautoml-start... Version 1 \n", 378 | "\n", 379 | " RunDate Duration PublicScore PrivateScore \n", 380 | "0 Sat Apr 10 2021 22:45:37 19373.4 0.81149 NaN \n", 381 | "1 Sat Apr 10 2021 07:19:31 21326.7 0.81125 NaN \n", 382 | "2 Sat Apr 10 2021 00:54:21 15522.1 0.81137 NaN \n", 383 | "3 Fri Apr 09 2021 21:23:29 5990.9 0.81060 NaN \n", 384 | "4 Fri Apr 09 2021 16:29:18 9285.7 0.80887 NaN \n", 385 | "5 Fri Apr 09 2021 09:17:58 12046.3 0.80947 NaN \n", 386 | "6 Fri Apr 09 2021 00:02:44 13446.1 0.80871 NaN \n", 387 | "7 Thu Apr 08 2021 22:15:04 5971.7 0.80782 NaN \n", 388 | "8 Wed Apr 07 2021 21:51:56 4235.3 0.80322 NaN \n", 389 | "9 Wed Apr 07 2021 09:12:04 4567.2 0.80253 NaN \n", 390 | "10 Wed Apr 07 2021 07:45:56 4891.3 NaN NaN \n", 391 | "11 Tue Apr 06 2021 22:57:15 13285.6 0.80237 NaN \n", 392 | "12 Tue Apr 06 2021 20:57:35 4164.7 0.80394 NaN \n", 393 | "13 Tue Apr 06 2021 19:43:04 288.7 0.80245 NaN \n", 394 | "14 Tue Apr 06 2021 15:45:21 7824.3 0.80007 NaN \n", 395 | "15 Tue Apr 06 2021 15:05:58 253.0 0.80176 NaN \n", 396 | "16 Sun Apr 04 2021 17:31:52 3457.2 NaN NaN \n", 397 | "17 Sun Apr 04 2021 00:26:13 26340.8 0.79664 NaN \n", 398 | "18 Sun Apr 04 2021 00:24:47 8.9 NaN NaN \n", 399 | "19 Sat Apr 03 2021 16:21:14 14235.7 0.79397 NaN \n", 400 | "20 Sat Apr 03 2021 11:56:14 10736.7 0.79688 NaN \n", 401 | "21 Thu Apr 01 2021 17:04:04 6450.4 0.79268 NaN \n", 402 | "22 Thu Apr 01 2021 15:13:29 3350.5 0.79837 NaN \n", 403 | "23 Thu Apr 01 2021 14:06:01 3218.6 NaN NaN \n", 404 | "24 Thu Apr 01 2021 12:05:33 3506.0 0.79058 NaN \n", 405 | "25 Thu Apr 01 2021 11:59:58 295.3 NaN NaN " 406 | ] 407 | }, 408 | "execution_count": 2, 409 | "metadata": {}, 410 | "output_type": "execute_result" 411 | } 412 | ], 413 | "source": [ 414 | "import pandas as pd\n", 415 | "\n", 416 | "info = pd.read_csv('output.csv')\n", 417 | "info" 418 | ] 419 | }, 420 | { 421 | "cell_type": "code", 422 | "execution_count": null, 423 | "metadata": {}, 424 | "outputs": [], 425 | "source": [] 426 | } 427 | ], 428 | "metadata": { 429 | "kernelspec": { 430 | "display_name": "Python 3", 431 | "language": "python", 432 | "name": "python3" 433 | }, 434 | "language_info": { 435 | "codemirror_mode": { 436 | "name": "ipython", 437 | "version": 3 438 | }, 439 | "file_extension": ".py", 440 | "mimetype": "text/x-python", 441 | "name": "python", 442 | "nbconvert_exporter": "python", 443 | "pygments_lexer": "ipython3", 444 | "version": "3.6.9" 445 | } 446 | }, 447 | "nbformat": 4, 448 | "nbformat_minor": 4 449 | } 450 | -------------------------------------------------------------------------------- /imgs/results.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alexmryzhkov/kaggle-kernels-helper/5a7e47f560c11c8ef84bae7d8d03984b08d5013d/imgs/results.png -------------------------------------------------------------------------------- /main.py: -------------------------------------------------------------------------------- 1 | from selenium import webdriver 2 | from lxml import html 3 | import pandas as pd 4 | import numpy as np 5 | from tqdm import tqdm 6 | import sys 7 | 8 | def get_scores_for_version(link, driver): 9 | driver.get("https://www.kaggle.com" + link) 10 | tree = html.fromstring(driver.page_source) 11 | public_els = tree.xpath("//div[@class='kernel-code-pane__submission-score-public']/div[2]/text()") 12 | private_els = tree.xpath("//div[@class='kernel-code-pane__submission-score-private']/div[2]/text()") 13 | 14 | public_score, private_score = np.nan, np.nan 15 | if len(public_els) > 0: 16 | public_score = float(public_els[0]) 17 | if len(private_els) > 0: 18 | private_score = float(private_els[0]) 19 | 20 | return public_score, private_score 21 | 22 | def main(kernel_url, fname): 23 | chrome_options = webdriver.ChromeOptions() 24 | chrome_options.add_argument('--headless') 25 | chrome_options.add_argument('--no-sandbox') 26 | driver = webdriver.Chrome('./chromedriver', chrome_options=chrome_options, 27 | service_args=['--verbose']) 28 | 29 | driver.get(kernel_url) 30 | driver.find_element_by_xpath("//span[contains(@class, 'fa fa-ellipsis-h')]").click() 31 | driver.find_element_by_xpath("//span[@name='history']").click() 32 | tree = html.fromstring(driver.page_source) 33 | 34 | rows = tree.xpath("//div[contains(@class, 'sc-kIzrRt eFtbII')]") 35 | statuses = [] 36 | links = [] 37 | names = [] 38 | run_dates = [] 39 | run_durations = [] 40 | for row in rows: 41 | status = row.xpath('./a[1]/i/text()') 42 | if len(status) > 0: 43 | statuses.append('OK' if status[0] == 'check_circle' else 'Failed') 44 | else: 45 | continue 46 | 47 | links.append(row.xpath('./a[1]/@href')[0]) 48 | names.append(row.xpath('./a[2]/text()')[0]) 49 | run_dates.append(row.xpath('./span[1]/a[1]/span/@title')[0][:24]) 50 | run_durations.append(float(row.xpath('./a[4]/text()')[0][:-1])) 51 | 52 | df = pd.DataFrame({ 53 | 'Status': statuses, 54 | 'Link': links, 55 | 'Name': names, 56 | 'RunDate': run_dates, 57 | 'Duration': run_durations 58 | }) 59 | 60 | scores = [] 61 | for link in tqdm(df['Link'].values, desc = 'Receiving scores for versions:'): 62 | scores.append(get_scores_for_version(link, driver)) 63 | 64 | driver.close() 65 | 66 | df['PublicScore'] = [x[0] for x in scores] 67 | df['PrivateScore'] = [x[1] for x in scores] 68 | if fname is not None: 69 | df.to_csv(fname, index = False) 70 | else: 71 | print(df) 72 | 73 | if __name__ == '__main__': 74 | if len(sys.argv) < 2: 75 | print('Example usage 1 (save results to file): python main.py ') 76 | print('Example usage 2 (print to stdout): python main.py ') 77 | else: 78 | kernel_url = sys.argv[1] 79 | fname = None 80 | if len(sys.argv) > 2: 81 | fname = sys.argv[2] 82 | main(kernel_url, fname) 83 | 84 | --------------------------------------------------------------------------------