{"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":"code","source":"import 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\nimport seaborn as sns\nimport plotly.express as px\nimport plotly.graph_objs as go\nimport plotly.offline as py\nimport plotly.express as px\nfrom plotly.offline import iplot","metadata":{"execution":{"iopub.status.busy":"2021-09-15T02:26:22.416665Z","iopub.execute_input":"2021-09-15T02:26:22.416993Z","iopub.status.idle":"2021-09-15T02:26:22.425135Z","shell.execute_reply.started":"2021-09-15T02:26:22.416960Z","shell.execute_reply":"2021-09-15T02:26:22.424336Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"df = pd.read_csv('../input/wikipedia-image-caption/train-00004-of-00005.tsv', sep='\\t',nrows=10000)\ndf.head(3)","metadata":{"_kg_hide-input":true,"execution":{"iopub.status.busy":"2021-09-15T02:44:00.222582Z","iopub.execute_input":"2021-09-15T02:44:00.223056Z","iopub.status.idle":"2021-09-15T02:44:00.669728Z","shell.execute_reply.started":"2021-09-15T02:44:00.223024Z","shell.execute_reply":"2021-09-15T02:44:00.668911Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Niharika Pandit https://www.kaggle.com/niharika41298/netflix-vs-books-recommender-analysis-eda\n\n#Ascending order False\ntop_rated=df.sort_values('original_height', ascending=False)\ntop10=top_rated.head(10)\nf=['page_title','image_url']\ndispl=(top10[f])\ndispl.set_index('page_title', inplace=True)","metadata":{"execution":{"iopub.status.busy":"2021-09-15T02:26:59.646103Z","iopub.execute_input":"2021-09-15T02:26:59.646420Z","iopub.status.idle":"2021-09-15T02:26:59.661401Z","shell.execute_reply.started":"2021-09-15T02:26:59.646389Z","shell.execute_reply":"2021-09-15T02:26:59.660528Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"#Code by Niharika Pandit https://www.kaggle.com/niharika41298/netflix-vs-books-recommender-analysis-eda\n\nfrom IPython.display import Image, HTML\n\ndef path_to_image_html(path):\n    '''\n     This function essentially convert the image url to \n     '<img src=\"'+ path + '\"/>' format. And one can put any\n     formatting adjustments to control the height, aspect ratio, size etc.\n     within as in the below example. \n    '''\n\n    return '<img src=\"'+ path + '\"\"/width=\"200\" height=\"40\" alt=\"Computer Hope\">'\n\nHTML(displ.to_html(escape=False ,formatters=dict(image_url=path_to_image_html),justify='center'))","metadata":{"execution":{"iopub.status.busy":"2021-09-15T02:27:09.744519Z","iopub.execute_input":"2021-09-15T02:27:09.744776Z","iopub.status.idle":"2021-09-15T02:27:09.755365Z","shell.execute_reply.started":"2021-09-15T02:27:09.744747Z","shell.execute_reply":"2021-09-15T02:27:09.754458Z"},"_kg_hide-input":true,"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"#At least I could plot some images since I wasn't able to make it in the previous Wikimedia Urllib.\n\n#Be patient, even to render those images it requires some time. Recycling code, from Netflix to Wikipedia.","metadata":{"execution":{"iopub.status.busy":"2021-09-15T02:34:14.489360Z","iopub.execute_input":"2021-09-15T02:34:14.489652Z","iopub.status.idle":"2021-09-15T02:34:14.495475Z","shell.execute_reply.started":"2021-09-15T02:34:14.489622Z","shell.execute_reply":"2021-09-15T02:34:14.494785Z"}}}]}