Skip to content

Instantly share code, notes, and snippets.

View pouyaardehkhani's full-sized avatar

Pouya Ardehkhani pouyaardehkhani

View GitHub Profile
@pouyaardehkhani
pouyaardehkhani / LaTeX math formulas.md
Created July 21, 2022 08:47
How to add LaTeX complicated math formulas to README.md

How to add LaTeX complicated math formulas to README.md

First write your math formula in LaTeX form. then go to this link https://editor.codecogs.com/ and paste your LaTeX code in it.(or you can create your formula there.)

It will generate a render link like this: c

Now go to your README.md file and copy this:

<img src="render link form that site">

Example:

@pouyaardehkhani
pouyaardehkhani / README.md
Last active February 20, 2025 22:08
How to create a python package and publish it to pypi in PyCharm

How to create a python package and publish it to pypi in PyCharm

Setup a new python project that we will package later

I typically use pycharm and create a new virtual environment (under the folder ‘venv’ – see below) that I use as the interpreter for that project:

  • After you create a new project on pycharm with Name of project =
  • Create a new package and name it.
  • Create a setup.py file outside of your package folder.
  • Create a version.py file in your package folder then write this in it __version__ = "your desired verstion" .
@pouyaardehkhani
pouyaardehkhani / Download_from_youtube.ipynb
Last active February 13, 2022 08:51
Download_from_youtube
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pouyaardehkhani
pouyaardehkhani / Writing LaTeX maths in Github markdown files.md
Created February 8, 2022 17:01
Writing LaTeX maths in Github markdown files

Use the text bellow to write LaTeX formulas in README.md files in Github.

<img src="https://render.githubusercontent.com/render/math?math=YOUR MATH FORMULA">

like this:

@pouyaardehkhani
pouyaardehkhani / Keep Google Colab from disconnecting markdown.md
Last active May 23, 2025 06:35
Keep Google Colab from disconnecting

Problem

I was training a deep learning model on Google Colab. I had to go somewhere for an emergency work. When I came back, I realized that Colab was disconnected; Therefore, I had to run the whole model again.

Solution

I searched on the Internet to solve this problem. I noticed that Colab will be disconnected if you don't click on the page. Here is an answer that I find:

function ClickConnect() {
  console.log('Working')
 document