Skip to content

Instantly share code, notes, and snippets.

View EdisonLeeeee's full-sized avatar

Jintang Li EdisonLeeeee

View GitHub Profile
@EdisonLeeeee
EdisonLeeeee / graph_tool_jupyter_notebook_inline_draw.ipynb
Created March 1, 2023 07:14 — forked from joshlk/graph_tool_jupyter_notebook_inline_draw.ipynb
Inline graph-tool figures in Jupyter notebook (graph_draw)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@EdisonLeeeee
EdisonLeeeee / gist:aa4e0c1f075be972a2054e27f673dc32
Created September 23, 2021 00:38 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: ๐Ÿ˜„ :smile: ๐Ÿ˜† :laughing:
๐Ÿ˜Š :blush: ๐Ÿ˜ƒ :smiley: โ˜บ๏ธ :relaxed:
๐Ÿ˜ :smirk: ๐Ÿ˜ :heart_eyes: ๐Ÿ˜˜ :kissing_heart:
๐Ÿ˜š :kissing_closed_eyes: ๐Ÿ˜ณ :flushed: ๐Ÿ˜Œ :relieved:
๐Ÿ˜† :satisfied: ๐Ÿ˜ :grin: ๐Ÿ˜‰ :wink:
๐Ÿ˜œ :stuck_out_tongue_winking_eye: ๐Ÿ˜ :stuck_out_tongue_closed_eyes: ๐Ÿ˜€ :grinning:
๐Ÿ˜— :kissing: ๐Ÿ˜™ :kissing_smiling_eyes: ๐Ÿ˜› :stuck_out_tongue:
@EdisonLeeeee
EdisonLeeeee / f1_score.py
Created May 10, 2021 12:19 — forked from SuperShinyEyes/f1_score.py
F1 score in PyTorch
def f1_loss(y_true:torch.Tensor, y_pred:torch.Tensor, is_training=False) -> torch.Tensor:
'''Calculate F1 score. Can work with gpu tensors
The original implmentation is written by Michal Haltuf on Kaggle.
Returns
-------
torch.Tensor
`ndim` == 1. 0 <= val <= 1