{"metadata":{"kernelspec":{"language":"python","display_name":"Python 3","name":"python3"},"language_info":{"pygments_lexer":"ipython3","nbconvert_exporter":"python","version":"3.6.4","file_extension":".py","codemirror_mode":{"name":"ipython","version":3},"name":"python","mimetype":"text/x-python"}},"nbformat_minor":4,"nbformat":4,"cells":[{"cell_type":"markdown","source":"# Place holder for code at discussion \n\ndiscussion url:\nhttps://www.kaggle.com/competitions/hubmap-organ-segmentation/discussion/332941\n\n\nCode is meant for illustration purpose (and not for execution purpose). \n\nI ran the code offline on my local PC. if you have memory issue in kaggle notebook, you will have to solve it yourselves, e.g. gradient checking, train using crop + finetune on image, etc\n\n\n**** disclaimer ****\n\n[1] the code is taken from a larger project and is by no means complete. It will has missing import modules, etc. But these are trival functions that you can ignore or fill in yourself.\n\n[2] you are free to use, modify the code for your own notebook or submission\n","metadata":{}},{"cell_type":"code","source":"#please see code in data section : folder \"upernet-swin-v1v2\"\n\n# there is no opensource code for swin transformer v2 for variable input size.\n# so i created one","metadata":{},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"4-fold validation and training log is found in folder \"train_log\".\nIt has public LB of 0.75.\n\n\n<table>\n<thead>\n  <tr>\n    <th>local cv</th>\n    <th></th>\n    <th></th>\n  </tr>\n</thead>\n<tbody>\n  <tr>\n    <td>fold-0</td>\n    <td></td>\n    <td></td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>all</td>\n    <td>0.715975</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>kidney</td>\n    <td>0.936300</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>prostate</td>\n    <td>0.793430</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>largeintestine</td>\n    <td>0.901231</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>spleen</td>\n    <td>0.798531</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>lung</td>\n    <td>0.129678</td>\n  </tr>\n  <tr>\n    <td>fold-1</td>\n    <td></td>\n    <td></td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>all</td>\n    <td>0.822849</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>kidney</td>\n    <td>0.944036</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>prostate</td>\n    <td>0.860772</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>largeintestine</td>\n    <td>0.898413</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>spleen</td>\n    <td>0.790220</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>lung</td>\n    <td>0.242596</td>\n  </tr>\n  <tr>\n    <td>fold-2</td>\n    <td></td>\n    <td></td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>all</td>\n    <td>0.798237</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>kidney</td>\n    <td>0.939717</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>prostate</td>\n    <td>0.849454</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>largeintestine</td>\n    <td>0.849303</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>spleen</td>\n    <td>0.851784</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>lung</td>\n    <td>0.208788</td>\n  </tr>\n  <tr>\n    <td>fold-3</td>\n    <td></td>\n    <td></td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>all</td>\n    <td>0.787423</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>kidney</td>\n    <td>0.939265</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>prostate</td>\n    <td>0.821587</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>largeintestine</td>\n    <td>0.904300</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>spleen</td>\n    <td>0.846358</td>\n  </tr>\n  <tr>\n    <td></td>\n    <td>lung</td>\n    <td>0.248889</td>\n  </tr>\n</tbody>\n</table>","metadata":{}}]}