{"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":"Published on May 23, 2023. By Marília Prata, mpwolke.","metadata":{}},{"cell_type":"code","source":"# This Python 3 environment comes with many helpful analytics libraries installed\n# It is defined by the kaggle/python Docker image: https://github.com/kaggle/docker-python\n# For example, here's several helpful packages to load\n\nimport numpy as np # linear algebra\nimport pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)\nimport matplotlib.pyplot as plt\nplt.style.use(\"ggplot\")\nimport seaborn as sns\n\nimport plotly.express as px\nimport plotly.graph_objs as go\n\nimport plotly\nplotly.offline.init_notebook_mode(connected=True)\n\nimport tifffile\nimport cv2\n\n#Ignore warnings\nimport warnings\nwarnings.filterwarnings('ignore')\n\n# Input data files are available in the read-only \"../input/\" directory\n# For example, running this (by clicking run or pressing Shift+Enter) will list all files under the input directory\n\nimport os\nfor dirname, _, filenames in os.walk('/kaggle/input'):\n    for filename in filenames:\n        print(os.path.join(dirname, filename))\n\n# You can write up to 20GB to the current directory (/kaggle/working/) that gets preserved as output when you create a version using \"Save & Run All\" \n# You can also write temporary files to /kaggle/temp/, but they won't be saved outside of the current session","metadata":{"_uuid":"8f2839f25d086af736a60e9eeb907d3b93b6e0e5","_cell_guid":"b1076dfc-b9ad-4769-8c92-a6c4dae69d19","_kg_hide-input":true,"_kg_hide-output":true,"execution":{"iopub.status.busy":"2023-05-23T23:20:05.833272Z","iopub.execute_input":"2023-05-23T23:20:05.833767Z","iopub.status.idle":"2023-05-23T23:20:15.714154Z","shell.execute_reply.started":"2023-05-23T23:20:05.833713Z","shell.execute_reply":"2023-05-23T23:20:15.713081Z"},"collapsed":true,"jupyter":{"outputs_hidden":true},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Human Reference Atlas-Vasculature Common Coordinate Framework (HRA-VCCF)\n\n\nCitation:\n\nBoppana, Avinash, Lee, Sujin, Malhotra, Rajeev, Halushka, Marc, Quardokus, Ellen M, Herr, Bruce W, Börner, Katy, & Weber, Griffin M. (2022). Human Reference Atlas-Vasculature Common Coordinate Framework (HRA-VCCF) (1.4.0) [Data set]. Zenodo. https://doi.org/10.5281/zenodo.7542316\n\nhttps://zenodo.org/record/7542316#.ZGz38n3MK3A","metadata":{}},{"cell_type":"markdown","source":"#Vessel CTB (Cell Types, plus Biomarkers) file\n\nHRA’s “Anatomical Structures, Cell Types, plus Biomarkers”","metadata":{}},{"cell_type":"code","source":"vessel = pd.read_csv(\"/kaggle/input/cusersmarildownloadsvesselcsv/vessel.csv\", delimiter=';', encoding='UTF-8')\npd.set_option('display.max_columns', None)\nvessel.head()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:37:36.998112Z","iopub.execute_input":"2023-05-23T23:37:36.998505Z","iopub.status.idle":"2023-05-23T23:37:37.055862Z","shell.execute_reply.started":"2023-05-23T23:37:36.998472Z","shell.execute_reply":"2023-05-23T23:37:37.054610Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Geometry file (HRA-VCCF)\n\nHuman Reference Atlas (HRA)\n\nHRA’s “Anatomical Structures, Cell Types, plus Biomarkers”","metadata":{}},{"cell_type":"code","source":"geo = pd.read_csv(\"/kaggle/input/cusersmarildownloadsgeocsv/geo.csv\", delimiter=';', encoding='ISO-8859-2')\npd.set_option('display.max_columns', None)\ngeo.head()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:40:15.356026Z","iopub.execute_input":"2023-05-23T23:40:15.356440Z","iopub.status.idle":"2023-05-23T23:40:15.388583Z","shell.execute_reply.started":"2023-05-23T23:40:15.356408Z","shell.execute_reply":"2023-05-23T23:40:15.387212Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"![](https://o.quizlet.com/9iZQbXwJ-cT9DqBcpkRPmQ.png)https://quizlet.com/33913587/glomerular-filtration-and-renal-blood-flow-flash-cards/","metadata":{}},{"cell_type":"markdown","source":"#Competition Citation:\n\n@misc{hubmap-hacking-the-human-vasculature,\n\n    author = {Addison Howard, HCL-Jevster, Katherine Gustilo, Katy Borner, Ryan Holbrook, Yashvardhan Jain},\n    \n    title = {HuBMAP - Hacking the Human Vasculature},\n    \n    publisher = {Kaggle},\n    \n    year = {2023},\n    \n    url = {https://kaggle.com/competitions/hubmap-hacking-the-human-vasculature}","metadata":{}},{"cell_type":"code","source":"tile = pd.read_csv(\"/kaggle/input/hubmap-hacking-the-human-vasculature/tile_meta.csv\", delimiter=',', encoding='UTF-8')\npd.set_option('display.max_columns', None)\ntile.head()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:20:59.792301Z","iopub.execute_input":"2023-05-23T23:20:59.792721Z","iopub.status.idle":"2023-05-23T23:20:59.852220Z","shell.execute_reply.started":"2023-05-23T23:20:59.792688Z","shell.execute_reply":"2023-05-23T23:20:59.851235Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Anmorgul https://www.kaggle.com/anmorgul/strange-pattern-cottonwood-willow\n#https://www.kaggle.com/code/mpwolke/roosevelt-forest-of-northern-colorado-charts\n\nfor i in range(4,5):\n    fig = px.scatter_3d(tile, x='dataset', y='i', z='j',\n                  color='source_wsi', size_max=8, width=1000, height=800, opacity=0.9, template=\"plotly_dark\")\n    fig.update_layout(\n        font_size=8,\n        legend_font_size=16,)\n    fig.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-24T00:03:25.964834Z","iopub.execute_input":"2023-05-24T00:03:25.965424Z","iopub.status.idle":"2023-05-24T00:03:26.068157Z","shell.execute_reply.started":"2023-05-24T00:03:25.965385Z","shell.execute_reply":"2023-05-24T00:03:26.067037Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#That 3D above is colorful, however I didn't get it. What's the interpretation of that?","metadata":{}},{"cell_type":"markdown","source":"#Whole Slide Images (WSI)\n\n\"To understand cell specialization, interactions, spatial organization in their natural context, and ultimately the function of every cell within the body. Multiple centers around the world are collecting tissue specimens from diverse populations that vary in age, race, sex, and body size.\"\n\nhttps://www.frontiersin.org/articles/10.3389/fcvm.2020.00029/full","metadata":{}},{"cell_type":"code","source":"wsi = pd.read_csv(\"/kaggle/input/hubmap-hacking-the-human-vasculature/wsi_meta.csv\", delimiter=',', encoding='UTF-8')\npd.set_option('display.max_columns', None)\nwsi.tail()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:51:00.985733Z","iopub.execute_input":"2023-05-23T23:51:00.986130Z","iopub.status.idle":"2023-05-23T23:51:01.006185Z","shell.execute_reply.started":"2023-05-23T23:51:00.986100Z","shell.execute_reply":"2023-05-23T23:51:01.005126Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Above, wsi_meta file. Only four rows?","metadata":{}},{"cell_type":"code","source":"#Code by Lucas Abrahão https://www.kaggle.com/lucasabrahao/trabalho-manufatura-an-lise-de-dados-no-brasil\n\ngeo[\"sex\"].value_counts().plot.barh(color=['blue', '#f5005a'], title='Participants on HRA Gender');","metadata":{"_kg_hide-input":true,"execution":{"iopub.status.busy":"2023-05-23T23:55:52.409917Z","iopub.execute_input":"2023-05-23T23:55:52.411150Z","iopub.status.idle":"2023-05-23T23:55:52.661647Z","shell.execute_reply.started":"2023-05-23T23:55:52.411110Z","shell.execute_reply":"2023-05-23T23:55:52.660536Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"vessel[\"CT1\"].value_counts()","metadata":{"execution":{"iopub.status.busy":"2023-05-24T00:11:43.949522Z","iopub.execute_input":"2023-05-24T00:11:43.949947Z","iopub.status.idle":"2023-05-24T00:11:43.961052Z","shell.execute_reply.started":"2023-05-24T00:11:43.949913Z","shell.execute_reply":"2023-05-24T00:11:43.959930Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#By Rob Mulla https://www.kaggle.com/code/robikscube/sign-language-recognition-eda-twitch-stream\n\nfig, ax = plt.subplots(figsize=(4, 4))\nvessel[\"vessel\"].value_counts().head(10).sort_values(ascending=True).plot(\n    kind=\"barh\", color='r', ax=ax, title=\"Vessels on HRA-VCCF\"\n)\nax.set_xlabel(\"Number of Training Examples\")\nplt.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-24T00:10:04.689162Z","iopub.execute_input":"2023-05-24T00:10:04.689673Z","iopub.status.idle":"2023-05-24T00:10:05.001984Z","shell.execute_reply.started":"2023-05-24T00:10:04.689631Z","shell.execute_reply":"2023-05-24T00:10:05.000812Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#By Rob Mulla https://www.kaggle.com/code/robikscube/sign-language-recognition-eda-twitch-stream\n\nfig, ax = plt.subplots(figsize=(4, 4))\nvessel[\"CT1\"].value_counts().head(10).sort_values(ascending=True).plot(\n    kind=\"barh\", color='purple', ax=ax, title=\"Cell Types on HRA-VCCF\"\n)\nax.set_xlabel(\"Number of Training Examples\")\nplt.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-24T00:12:57.686694Z","iopub.execute_input":"2023-05-24T00:12:57.687614Z","iopub.status.idle":"2023-05-24T00:12:57.943153Z","shell.execute_reply.started":"2023-05-24T00:12:57.687555Z","shell.execute_reply":"2023-05-24T00:12:57.942038Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"wsi.info()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:23:43.953146Z","iopub.execute_input":"2023-05-23T18:23:43.953537Z","iopub.status.idle":"2023-05-23T18:23:43.980612Z","shell.execute_reply.started":"2023-05-23T18:23:43.953507Z","shell.execute_reply":"2023-05-23T18:23:43.979380Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"wsi.describe()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:24:16.558962Z","iopub.execute_input":"2023-05-23T18:24:16.559356Z","iopub.status.idle":"2023-05-23T18:24:16.594932Z","shell.execute_reply.started":"2023-05-23T18:24:16.559325Z","shell.execute_reply":"2023-05-23T18:24:16.593659Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"sub = pd.read_csv(\"/kaggle/input/hubmap-hacking-the-human-vasculature/sample_submission.csv\", delimiter=',', encoding='UTF-8')\n\nsub.head()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:04:14.130416Z","iopub.execute_input":"2023-05-23T18:04:14.130819Z","iopub.status.idle":"2023-05-23T18:04:14.151238Z","shell.execute_reply.started":"2023-05-23T18:04:14.130787Z","shell.execute_reply":"2023-05-23T18:04:14.150425Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by StackOverflow https://stackoverflow.com/questions/50475635/loading-jsonl-file-as-json-objects\n\njsonObj = pd.read_json(path_or_buf= '../input/hubmap-hacking-the-human-vasculature/polygons.jsonl', lines=True)\n\n\njsonObj.head()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:16:17.810315Z","iopub.execute_input":"2023-05-23T18:16:17.810731Z","iopub.status.idle":"2023-05-23T18:16:23.517551Z","shell.execute_reply.started":"2023-05-23T18:16:17.810699Z","shell.execute_reply":"2023-05-23T18:16:23.516163Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#No Missing values on JsonL","metadata":{}},{"cell_type":"code","source":"jsonObj.isnull().sum()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:16:56.632810Z","iopub.execute_input":"2023-05-23T18:16:56.633288Z","iopub.status.idle":"2023-05-23T18:16:56.646753Z","shell.execute_reply.started":"2023-05-23T18:16:56.633199Z","shell.execute_reply":"2023-05-23T18:16:56.645080Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Annotations. A list of mask annotations with:\n\nType Identifies the type of structure annotated:\n\nBlood_vessel: The target structure. Your goal in this competition is to predict these kinds of masks on the test set.\n\nGlomerulus: A capillary ball structure in the kidney. These parts of the images were excluded from blood vessel annotation. You should ensure none of your test set predictions occur within glomerulus \nstructures as they will be counted as false positives. Annotations are provided for test set tiles.\n\nUnsure: A structure the expert annotators cannot confidently distinguish as a blood vessel.\ncoordinates A list of polygon coordinates defining the segmentation mask.\n\nhttps://www.kaggle.com/competitions/hubmap-hacking-the-human-vasculature/data","metadata":{}},{"cell_type":"code","source":"#Code by Ventakumar R https://www.kaggle.com/venkatkumar001/hfp-2-eda-tensorflow/notebook\n\nann = pd.DataFrame(jsonObj['annotations'])\n#train_cat.columns = [ 'category_id', 'scientificName','family', 'genus']\ndisplay(ann)","metadata":{"execution":{"iopub.status.busy":"2023-05-23T18:20:03.566761Z","iopub.execute_input":"2023-05-23T18:20:03.567223Z","iopub.status.idle":"2023-05-23T18:20:03.694726Z","shell.execute_reply.started":"2023-05-23T18:20:03.567184Z","shell.execute_reply":"2023-05-23T18:20:03.692376Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"anatomical_files = [os.path.basename(f) for f in glob.glob(TRAIN_HOME + \"*.tif\") if \"anatomical\" in f]\nmasks_files = [os.path.basename(f) for f in glob.glob(TRAIN_HOME + \"*.tif\") if \"anatomical\" not in f]\nmasks_files","metadata":{"execution":{"iopub.status.busy":"2023-05-23T19:16:06.747992Z","iopub.execute_input":"2023-05-23T19:16:06.749163Z","iopub.status.idle":"2023-05-23T19:16:06.842846Z","shell.execute_reply.started":"2023-05-23T19:16:06.749120Z","shell.execute_reply":"2023-05-23T19:16:06.841727Z"},"_kg_hide-output":true,"collapsed":true,"jupyter":{"outputs_hidden":true},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"import math\nimport glob\n\nimport cv2\nimport matplotlib.pyplot as plt\nimport seaborn as sn\n\nimport json\nimport numpy as np\n\nimport tifffile as tiff\nfrom matplotlib import colors\nfrom matplotlib import pyplot as plt\nfrom matplotlib.lines import Line2D\nfrom matplotlib_venn import venn2_unweighted","metadata":{"_kg_hide-output":true,"execution":{"iopub.status.busy":"2023-05-23T23:26:11.292156Z","iopub.execute_input":"2023-05-23T23:26:11.292577Z","iopub.status.idle":"2023-05-23T23:26:11.313384Z","shell.execute_reply.started":"2023-05-23T23:26:11.292547Z","shell.execute_reply":"2023-05-23T23:26:11.312186Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Georgii Kostiuchik https://www.kaggle.com/code/georgiikostiuchik/hubmap-exploratory-data-analysis\n\ntrain_images = glob.glob('/kaggle/input/hubmap-hacking-the-human-vasculature/train/*.tif')\ntest_images = glob.glob('/kaggle/input/hubmap-hacking-the-human-vasculature/test/*.tif')\n\ntrain_images = list(map(lambda x: os.path.basename(x), train_images))\ntest_images = list(map(lambda x: os.path.basename(x), test_images))","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:27:28.150733Z","iopub.execute_input":"2023-05-23T23:27:28.151921Z","iopub.status.idle":"2023-05-23T23:27:28.197629Z","shell.execute_reply.started":"2023-05-23T23:27:28.151883Z","shell.execute_reply":"2023-05-23T23:27:28.196456Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Georgii Kostiuchik https://www.kaggle.com/code/georgiikostiuchik/hubmap-exploratory-data-analysis\n\n# open and resize image\nimage = cv2.imread('/kaggle/input/hubmap-hacking-the-human-vasculature/train/401cc7fbcf22.tif')\nimage_resize = cv2.resize(image,(image.shape[1]//10,image.shape[0]//10), interpolation = cv2.INTER_CUBIC)","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:28:52.516809Z","iopub.execute_input":"2023-05-23T23:28:52.517974Z","iopub.status.idle":"2023-05-23T23:28:52.606984Z","shell.execute_reply.started":"2023-05-23T23:28:52.517937Z","shell.execute_reply":"2023-05-23T23:28:52.605825Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Georgii Kostiuchik https://www.kaggle.com/code/georgiikostiuchik/hubmap-exploratory-data-analysis\n\n# calculate colors\npixel_colors = image_resize.reshape((np.shape(image_resize)[0]*np.shape(image_resize)[1], 3))\nnorm = colors.Normalize(vmin=-1.,vmax=1.)\nnorm.autoscale(pixel_colors)\npixel_colors = norm(pixel_colors).tolist()\n\n# split channels\nb, g, r = cv2.split(image_resize)\n\n# scatter plot\nfig = plt.figure()\naxis = fig.add_subplot(1, 1, 1, projection='3d')\naxis.scatter(r.flatten(), g.flatten(), b.flatten(), facecolors=pixel_colors, marker='.')\naxis.set_xlabel('Red')\naxis.set_ylabel('Green')\naxis.set_zlabel('Blue')\nplt.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:29:14.968693Z","iopub.execute_input":"2023-05-23T23:29:14.969051Z","iopub.status.idle":"2023-05-23T23:29:15.310647Z","shell.execute_reply.started":"2023-05-23T23:29:14.969024Z","shell.execute_reply":"2023-05-23T23:29:15.309573Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Georgii Kostiuchik https://www.kaggle.com/code/georgiikostiuchik/hubmap-exploratory-data-analysis\n\n# convert to hsv\nhsv_image = cv2.cvtColor(image_resize, cv2.COLOR_BGR2HSV)\nh, s, v = cv2.split(hsv_image)\n\n# scatter plot\nfig = plt.figure()\naxis = fig.add_subplot(1, 1, 1, projection='3d')\naxis.scatter(s.flatten(), h.flatten(), v.flatten(), facecolors=pixel_colors, marker='.')\naxis.set_xlabel('Saturation')\naxis.set_ylabel('Hue')\naxis.set_zlabel('Value')\nplt.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:29:53.013900Z","iopub.execute_input":"2023-05-23T23:29:53.014260Z","iopub.status.idle":"2023-05-23T23:29:53.338624Z","shell.execute_reply.started":"2023-05-23T23:29:53.014234Z","shell.execute_reply":"2023-05-23T23:29:53.337496Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"DATA_PATH = \"../input/hubmap-hacking-the-human-vasculature\"","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:30:49.035114Z","iopub.execute_input":"2023-05-23T23:30:49.036176Z","iopub.status.idle":"2023-05-23T23:30:49.041250Z","shell.execute_reply.started":"2023-05-23T23:30:49.036126Z","shell.execute_reply":"2023-05-23T23:30:49.040088Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"image_paths = sorted(glob.glob(os.path.join(DATA_PATH, 'train/*.tif')))","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:31:21.601393Z","iopub.execute_input":"2023-05-23T23:31:21.602661Z","iopub.status.idle":"2023-05-23T23:31:21.640672Z","shell.execute_reply.started":"2023-05-23T23:31:21.602613Z","shell.execute_reply":"2023-05-23T23:31:21.639695Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print(f\"Number of images: {len(image_paths)}\")","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:31:40.564292Z","iopub.execute_input":"2023-05-23T23:31:40.564666Z","iopub.status.idle":"2023-05-23T23:31:40.570822Z","shell.execute_reply.started":"2023-05-23T23:31:40.564637Z","shell.execute_reply":"2023-05-23T23:31:40.569469Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Ihelon https://www.kaggle.com/code/ihelon/illustrations-kumapi390-eda\n\nimage_shapes = {}\n\nfor ind, image_path in enumerate(image_paths):\n    image = cv2.imread(image_path)\n    image_shapes[image.shape] = image_shapes.get(image.shape, 0) + 1\n    \nimage_shapes","metadata":{"execution":{"iopub.status.busy":"2023-05-23T23:32:02.774359Z","iopub.execute_input":"2023-05-23T23:32:02.774747Z","iopub.status.idle":"2023-05-23T23:35:30.910328Z","shell.execute_reply.started":"2023-05-23T23:32:02.774717Z","shell.execute_reply":"2023-05-23T23:35:30.908973Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Always Ihelon's code to save me","metadata":{}},{"cell_type":"code","source":"#Code by Ihelon https://www.kaggle.com/code/ihelon/illustrations-kumapi390-eda\n\nn_cols = 4\nn_rows = 4\n\nfor ind, image_path in enumerate(image_paths):\n    image = cv2.imread(image_path)\n    image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB)\n    \n    if ind % n_cols == 0:\n        plt.figure(figsize=(16, 5))\n    plt.subplot(1, n_cols, ind % n_cols + 1)\n    plt.imshow(image)\n    plt.axis(\"off\")\n    if ind % n_cols == n_cols - 1:\n        plt.show()","metadata":{"execution":{"iopub.status.busy":"2023-05-24T00:14:52.649348Z","iopub.execute_input":"2023-05-24T00:14:52.649874Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#Acknowledgements:\n\nIhelon https://www.kaggle.com/code/ihelon/illustrations-kumapi390-eda\n\nGeorgii Kostiuchik https://www.kaggle.com/code/georgiikostiuchik/hubmap-exploratory-data-analysis\n\nAnmorgul https://www.kaggle.com/anmorgul/strange-pattern-cottonwood-willow\n\nRob Mulla https://www.kaggle.com/code/robikscube/sign-language-recognition-eda-twitch-stream","metadata":{}}]}