{"id":13701484,"url":"https://github.com/hahnlee/ipytracer","last_synced_at":"2025-10-02T10:32:23.430Z","repository":{"id":57276719,"uuid":"74150450","full_name":"hahnlee/ipytracer","owner":"hahnlee","description":" :bar_chart: Algorithm Visualizer for IPython/Jupyter Notebook","archived":true,"fork":false,"pushed_at":"2017-07-16T12:27:35.000Z","size":19585,"stargazers_count":136,"open_issues_count":4,"forks_count":12,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-09-24T21:33:18.326Z","etag":null,"topics":["algorithm","algorithm-visualizer","ipython","ipython-notebook","javascript","jupyter","jupyter-notebook","jupyterhub-labextension","python"],"latest_commit_sha":null,"homepage":"http://ipytracer.readthedocs.io/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause-clear","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hahnlee.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-11-18T17:08:28.000Z","updated_at":"2024-08-08T14:18:17.000Z","dependencies_parsed_at":"2022-08-25T00:21:14.085Z","dependency_job_id":null,"html_url":"https://github.com/hahnlee/ipytracer","commit_stats":null,"previous_names":["sn0wle0pard/ipytracer"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hahnlee%2Fipytracer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hahnlee%2Fipytracer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hahnlee%2Fipytracer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hahnlee%2Fipytracer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hahnlee","download_url":"https://codeload.github.com/hahnlee/ipytracer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219875673,"owners_count":16554698,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithm","algorithm-visualizer","ipython","ipython-notebook","javascript","jupyter","jupyter-notebook","jupyterhub-labextension","python"],"created_at":"2024-08-02T20:01:42.021Z","updated_at":"2025-10-02T10:32:17.929Z","avatar_url":"https://github.com/hahnlee.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# ipytracer\n\n\u003e Algorithm Visualizer for Jupyter/IPython Notebook\n\n\u003e Inspired by parkjs814's [AlgorithmVisualizer](https://github.com/parkjs814/AlgorithmVisualizer).\n\nMaster | Latest(0.2.2)\n-------|-------\n[![tv-master-img][]][tv-site]|[![tv-latest-img][]][tv-site]\n\n[tv-master-img]: https://travis-ci.org/sn0wle0pard/ipytracer.svg?branch=master\n[tv-latest-img]: https://travis-ci.org/sn0wle0pard/ipytracer.svg?branch=latest\n[tv-site]: https://travis-ci.org/sn0wle0pard/ipytracer\n\n![pypi](https://anaconda.org/sn0wle0pard/tracer.py/badges/installer/pypi.svg)\n![anaconda](https://anaconda.org/sn0wle0pard/tracer.py/badges/version.svg)\n\nAlgorithm Visualizer for Jupyter/IPython Notebook.\n\nIt was inspired by parkjs814's [AlgorithmVisualizer](https://github.com/parkjs814/AlgorithmVisualizer).\n\nYou can see how your Python code works.\n\nIf you use the `display(TracerObject)` code from where you want to see, you can use it without any special modification.\n\nSupports built-in list methods.\n\n# Development Status\nPre-Alpha\n\n# Todo\n- Add more tracer api\n- Support non-built-in data type in python\n\n# Installation\nRequirement\n- Jupyter/IPython Notebook (Python3.x)\n\nTo install use pip:\n```console\n$ pip install ipytracer\n$ jupyter nbextension enable --py --sys-prefix ipytracer\n```\n\nFor a development installation (requires npm),\n\nPre installation\n```console\n$ npm install -g webpack\n```\nInstallation\n```console\n$ git clone https://github.com/sn0wle0pard/ipytracer.git\n$ cd ipytracer\n$ pip install -e .\n$ jupyter nbextension install --py --symlink --sys-prefix ipytracer\n$ jupyter nbextension enable --py --sys-prefix ipytracer\n```\n# Demo\n## Youtube Video\n[![Alt text](https://img.youtube.com/vi/vZQJ0Y3GtIs/0.jpg)](https://www.youtube.com/watch?v=vZQJ0Y3GtIs)\n\nhttps://youtu.be/vZQJ0Y3GtIs\n\n## Tracers\n### List1DTracer\n\nDisplay | Get Item | Set Item\n--------|----------|---------\n![List1DBasic](src/list1d-basic.png) | ![List1DGet](src/list1d-getitem.png) | ![list1DSet](src/list1d-setitem.png)\n\n### List2DTracer\n\nGet Item | Set Item\n---------|---------\n![List2DRowGet](src/list2d-row-get.png)| ![List2DRowSet](src/list2d-row-set.png)\n![List2DColGet](src/list2d-col-get.png)| ![List2DColSet](src/list2d-col-set.png)\n### ChartTracer\n\nDisplay | Get Item | Set Item\n--------|----------|---------\n![ChartBasic](src/chart-basic.png) | ![ChartGet](src/chart-get.png) | ![ChartSet](src/chart-set.png)\n## Bubble Sort\n\n```python\nimport ipytracer\nfrom IPython.core.display import display\n\ndef bubble_sort(unsorted_list):\n    x = ipytracer.ChartTracer(unsorted_list)\n    display(x)\n    length = len(x)-1\n    for i in range(length):\n        for j in range(length-i):\n            if x[j] \u003e x[j+1]:\n                x[j], x[j+1] = x[j+1], x[j]\n    return x.tolist()\n\nbubble_sort([6,4,7,9,3,5,1,8,2])\n```\n\n![BubbleSortWork](src/bubble_chart.gif)\n\nYou can see more example [here](https://github.com/sn0wle0pard/tracer/tree/master/example)\n\nThird Party Libraries\n-----\n* Chart.js - http://www.chartjs.org\n* IPython - https://ipython.org\n* ipywidgets - https://ipywidgets.readthedocs.io\n* traitlets - https://traitlets.readthedocs.io/\n* Underscore - http://underscorejs.org\n* Webpack - https://webpack.github.io\n\nSee Also [NOTICE.md](NOTICE.md)\n\nAuthor\n------\n\nHan Lee / [@sn0wle0pard](https://github.com/sn0wle0pard)\n\nLicense\n-------\n```\nThe Clear BSD License\n\nCopyright (c) 2015-2017, Han Lee\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted (subject to the limitations in the disclaimer\nbelow) provided that the following conditions are met:\n\n* Redistributions of source code must retain the above copyright notice, this\n  list of conditions and the following disclaimer.\n\n* Redistributions in binary form must reproduce the above copyright notice,\n  this list of conditions and the following disclaimer in the documentation\n  and/or other materials provided with the distribution.\n\n* Neither the name of the copyright holder nor the names of its contributors may be used\n  to endorse or promote products derived from this software without specific\n  prior written permission.\n\nNO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED BY THIS\nLICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n\"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,\nTHE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\nARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\nLIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\nCONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE\nGOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)\nHOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\nLIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT\nOF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH\nDAMAGE.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhahnlee%2Fipytracer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhahnlee%2Fipytracer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhahnlee%2Fipytracer/lists"}