Welcome to Next.js!

Get started by editing pages/index.js

In this article

Hi, I'm Eugene Yan, an ML engineer.

Don't Mock Machine Learning Models In Unit Tests

How unit testing machine learning code differs from typical software practices

25 Feb 2024  ·  6 min  · machinelearningengineering

Further reading

Text-to-Image: Diffusion, Text Conditioning, Guidance, Latent Space

The fundamentals of text-to-image generation, relevant papers, and experimenting with DDPM.

27 Nov 2022  ·  19 min  · Eugene Yandeeplearningnlpsurvey

Andrew Gibiansky   ::   Math → [Code]

I am a research scientist at Google DeepMind interested in making generative AI safe for everyone to use through research on uncertainty estimation, watermarking, adversarial robustness, or out-of-distribution detection, among other topics. Previously, I focused on computer vision, including 3D reconstruction and image segmentation.

ARTICLE

Implementing Custom PyTorch Tensor Operations in C and CUDA

PyTorch, alongside TensorFlow, has become standard among deep learning researchers and practitioners. While PyTorch provides a large variety in terms of tensor operations or deep learning layers, some specialized operations still need to be implemented manually. In cases where runtime is crucial, this should be done in C or CUDA for supporting both CPU and GPU computation. In this article, I want to provide a simple example and framework for extending PyTorch with custom C and CUDA operations using CFFI for Python and CuPy.

More ...

ARTICLE

ArXiv Pre-Print “Adversarial Training against Location-Optimized Adversarial Patches”

While robustness against imperceptible adversarial examples is well-studied, robustness against visible adversarial perturbations such as adversarial patches is poorly understood. In this pre-print, we present a practical approach to obtain adversarial patches while actively optimizing their location within the image. On Cifar10 and GTSRB, we show that adversarial training on these location-optimized adversarial patches improves robustness significantly while not reducing accuracy.

More ...

https://github.com/gibiansky/experiments

Projects:

  • lbm/ - Simple implementation of the Lattice Boltzmann method; described a little bit on one of my blog posts.
  • fluids/ - Experiments with a fluid simulation method known as Smoothed Particle Hydrodynamics. Includes a complete description of the simulation method, starting from fundamental fluid mechanics to derive the Navier-Stokes equations, followed by a derivation of the simulation steps from the Navier-Stokes equations. Also includes a very quick and dirty Java implementation of the simulation method. Also available as a pair of blog posts for more detail.
  • morph/ - Experiments with simple image interpolation / morphing. Take a look at the blog post for more detail.
  • neural-network/ - An implementation of a feed-forward neural network in MATLAB for handwritten digit recognition. For information on neural networks, take a look at the following explanation.
  • cpu/ - A toy CPU created in Verilog for use with a Cyclone II Altera Starter Kit FPGA board. The CPU executes (compiled versions of) a custom MIPS-like assembly language; the compiler for this language and the description are in simple/.
  • simple/ - A toy C-like language called "Simple", which compiles to a custom MIPS-like assembly, which can execute on a custom CPU for a Cyclone II FPGA board.
  • quadcopter/ - A detailed description of quadcopter motion dynamics and the control used for quadcopter stabilization. Includes a simulation and movie.
  • lbm/ - Simple implementation of the Lattice Boltzmann method; described a little bit on one of my blog posts.
  • fluids/ - Experiments with a fluid simulation method known as Smoothed Particle Hydrodynamics. Includes a complete description of the simulation method, starting from fundamental fluid mechanics to derive the Navier-Stokes equations, followed by a derivation of the simulation steps from the Navier-Stokes equations. Also includes a very quick and dirty Java implementation of the simulation method. Also available as a pair of blog posts for more detail.
  • morph/ - Experiments with simple image interpolation / morphing. Take a look at the blog post for more detail.
  • neural-network/ - An implementation of a feed-forward neural network in MATLAB for handwritten digit recognition. For information on neural networks, take a look at the following explanation.
  • cpu/ - A toy CPU created in Verilog for use with a Cyclone II Altera Starter Kit FPGA board. The CPU executes (compiled versions of) a custom MIPS-like assembly language; the compiler for this language and the description are in simple/.
  • simple/ - A toy C-like language called "Simple", which compiles to a custom MIPS-like assembly, which can execute on a custom CPU for a Cyclone II FPGA board.
  • quadcopter/ - A detailed description of quadcopter motion dynamics and the control used for quadcopter stabilization. Includes a simulation and movie.