Skip to content

Instantly share code, notes, and snippets.

View HSILA's full-sized avatar

HSILA HSILA

  • McMaster University
  • Canada
  • 15:53 (UTC -05:00)
View GitHub Profile
@HSILA
HSILA / intfloat__e5-small-v2.json
Created January 12, 2026 17:17
ChemRxivRetrieval MTEB sanity check
{
"dataset_revision": "5377aa18f309ec440ff6325a4c2cd3362c2cb8d7",
"task_name": "ChemRxivRetrieval",
"mteb_version": "2.6.8",
"scores": {
"test": [
{
"ndcg_at_1": 0.625,
"ndcg_at_3": 0.71766,
"ndcg_at_5": 0.74022,
\documentclass[tikz,border=2pt]{standalone}
\usepackage{amsmath,bm}
\usepackage{tikz}
% \usetikzlibrary{arrows.meta} % if you need extra arrowheads
\begin{document}
\begin{tikzpicture}
\node at (0,1.8) (h) {$\longleftarrow\,$Representation$\,\longrightarrow$};
\node[draw, circle] at (0,-1) (x) {$\bm{x}$};
\node[draw, circle] at (-2.5,0) (x1) {$\tilde{\bm{x}}_i$};
\node[draw, circle] at (2.5,0) (x2) {$\tilde{\bm{x}}_j$};
@HSILA
HSILA / BiEncoderWrapper.py
Created April 23, 2025 05:01
contrastors BiEncoderWrapper
import os
import numpy as np
from typing import Any
import torch
import mteb
from transformers import AutoTokenizer
@HSILA
HSILA / onnx_cumsum.py
Last active July 2, 2022 06:15
ONNX CumSum operator shouldn't get boolean but model checker won't check it
import torch
from torch import nn
import onnx
import onnxruntime
a = torch.tensor([12, 0, 5, 154], dtype=torch.float32)
# a.to(torch.bool) = tensor([True, False, True, True])
# ~a.to(torch.bool) = tensor([False, True, False, False])