Skip to content

Instantly share code, notes, and snippets.

@francois-rozet
francois-rozet / flow_matching.py
Last active July 1, 2024 19:03
Flow Matching in 100 LOC
#!/usr/bin/env python
import math
import matplotlib.pyplot as plt
import torch
import torch.nn as nn
from sklearn.datasets import make_moons
from torch import Tensor
from tqdm import tqdm