Path tracer with BVH acceleration
Summer 2026
CS 184 · C++ · partner project
A Monte Carlo path tracer with a bounding volume hierarchy for acceleration, importance-sampled direct lighting, Russian roulette termination, and adaptive per-pixel sampling, rendering at 2048+ spp.
C++Monte CarloBVHimportance sampling
Full detail
- Bounding volume hierarchy with recursive spatial partitioning and interval pruning on traversal; split on midpoint or centroid average.
- Direct lighting implemented 2 ways, uniform hemisphere vs. importance sampling by light, compared at matched sample counts.
- Russian roulette at 0.3-0.4 continuation probability, always at least 1 indirect bounce. Unbiased, bounded expected depth.
- Adaptive sampling: halt a pixel once 1.96σ/√n is within 5% of its running mean, checked every 32 samples.
- Final renders at 2048+ spp, max ray depth 5.
7 memory-safety exploits
Summer 2026
CS 161 · C / x86 / GDB
Seven working memory-safety exploits that escalate from an undefended stack to canaries and ASLR defeated together, using return-address overwrites, format strings, and NOP sleds.
Cx86GDBexploit scripting
Full detail
- 7 working exploits, each named for a star, escalating from an undefended stack to canaries + ASLR together.
- Return-address overwrite 20 bytes past an unbounded
gets, with injected shellcode.
- Defeated 4-byte canaries by overwriting the saved RIP with the canary left intact through the epilogue.
- Off-by-one overflow with shellcode staged in an environment variable.
- Format string turned into an arbitrary write via 2
%hn half-writes of a 32-bit address.
- NOP sled against canaries and ASLR simultaneously, landing within 5 attempts.
BYOW, procedural 2D world engine
Spring 2025
CS 61B · Java · partner project
A procedural 2D world engine seeded across the full positive long range, with reachability and coverage guarantees, a line-of-sight renderer, and byte-identical save and load.
Javaprocedural generationserializationdeterministic sim
Full detail
- Seeded across the full positive
long range, 0 to 9,223,372,036,854,775,807, with no fixed world size.
- 3 structural guarantees: ≥50% floor coverage, 100% mutual reachability, 0 dead-end hallways.
- Line-of-sight renderer, keypress-toggleable, drawing only tiles the avatar can see with walls occluding behind them.
- Byte-identical save/load: same seed and keystrokes reproduce exact state, which requires RNG state to persist, not just the tile grid.
- Assessed by live TA checkoff, so it has to run in front of a person.
Scheme interpreter
Fall 2024
CS 61A · Python · 18 problems
A Scheme evaluator with eval/apply mutual recursion and lexical scoping, plus tail-call optimization by trampolining that I added beyond the spec.
Pythoninterpretersenvironment modelTCO
Full detail
- Wrote the evaluator:
eval/apply mutual recursion, frame construction, lexical scoping, and the lambda / define / quote / short-circuiting and and or forms. Tokenizer and reader were provided.
mu, a dynamically-scoped procedure differing from lambda by exactly one line: whether the new frame's parent is the defining or the calling environment.
- Tail-call optimization by trampolining, thunks returned from tail positions and forced in a driver loop, giving unbounded tail recursion inside a Python host with none. Not required by the spec; I wanted it to work.
CS61Classify, neural net in RISC-V assembly
Summer 2025
CS 61C · hand-written RV32, no C
A two-layer fully-connected digit classifier written entirely in RISC-V assembly, with matrix-multiply, ReLU, and argmax kernels built from scratch.
RISC-V asmVenuscalling conventionLA kernels
Full detail
- 2-layer fully-connected network classifying handwritten digits entirely in assembly:
argmax(matmul(m1, relu(matmul(m0, x)))) over 784-element flattened 28×28 inputs.
- Kernels from scratch: absolute value, ReLU, argmax with lowest-index tie-breaking, strided dot product, matrix multiply.
- Strides given in elements, not bytes, so every address computation scales by 4.
- Binary matrix file I/O through raw syscalls with 9 distinct error codes.
s0 through s11 banned in Part A; 100% test coverage and a calling-convention checker enforced.
Half-edge mesh editor
Summer 2026
CS 184 · C++ · partner project
A half-edge mesh editor with edge flip and split, Loop subdivision, and de Casteljau Bezier surfaces, documented in a 25-figure write-up.
C++half-edge meshesLoop subdivisionde Casteljau
Full detail
- Edge flip and edge split on a half-edge mesh, local rewirings of twin, next, vertex, edge and face pointers, where one missed reassignment tears the mesh on subdivision.
- Loop subdivision: 4-to-1 split, selective flipping of new edges joining old vertices to new, repositioning at 3/8(A+B) + 1/8(C+D).
- de Casteljau Bezier curves and surfaces, evaluated separably across an n×n control grid.
- Area-weighted vertex normals by half-edge circulation. Write-up, 25 figures →
Acoustic positioning system
Fall 2024
EECS 16A · Python
A microphone localized in 2D from 6 speakers by cross-correlating Gold codes, solving a three-unknown least-squares system I wrote from scratch.
Pythoncross-correlationGold codesleast squaresTDOA
Full detail
- Localized a microphone in 2D from 6 speakers at 44.1 kHz over a ~2.5 s recording. Speed of sound 34,029 cm/s.
- Beacon separation by cross-correlation against 511-chip Gold codes, 20 samples/chip, a 231.7 ms loop averaged over ~10.8 repetitions.
- 12 kHz carrier, complex-demodulated through a 45-tap FIR low-pass.
- 3 unknowns, not 2, because the reference beacon's absolute time-of-flight is unknown too, the same reason GPS needs 4 satellites for a 3D fix.
- Linearized by differencing into an overdetermined 5×3 system; least-squares solver written from scratch, built-ins forbidden.
Shazam, audio fingerprinting
Fall 2024
EECS 16A · Python
An audio fingerprinting system that hashes spectrogram constellation maps and still identifies a track with 50% of the audio zeroed and under heavy noise.
PythonSciPySTFTpeak detectionhashing
Full detail
- 48 kHz audio, 2.88 M samples a track, spectrogram to hash database to match.
- 4096-point STFT, the DFT length production fingerprinting systems use.
- Constellation map by 51×51 maximum filtering above amplitude threshold 40, on the linear spectrogram, and converting to dB fails the tests.
- Each peak chained to the next 15 into a 9,184-row database.
- Identifies correctly with 50% of the audio zeroed and under Gaussian noise at mean 10,000, σ 10,000.
Rasterizer
Summer 2026
CS 184 · C++ · partner project
A triangle rasterizer with supersampled antialiasing up to 16 spp and trilinear mipmapping derived from UV-space screen derivatives.
C++supersamplingmipmappingbarycentric
Full detail
- Supersampled antialiasing at 1, 4 and 16 spp, sampled on a √n × √n grid into a floating-point buffer, resolved into 8 bits.
- Bounding-box-limited point-in-triangle handling both winding orders, attributes interpolated barycentrically.
- Mipmap level sampling in 3 modes up to full trilinear, derived from UV-space screen derivatives.
- 6 sampling configurations benchmarked on speed vs. memory vs. antialiasing power.
Single-pixel camera
Fall 2024
EECS 16A · Python · Arduino
A full 2D image reconstructed from 1 photosensor and no lens, using Hadamard multiplexing masks chosen over random ones on eigenvalue grounds.
Pythonlinear systemsmatrix conditioningHadamard
Full detail
- Full 2D image from 1 photosensor and no lens, solving a 1200×1200 system over 1200 sequential exposures.
- Multiplexed masks illuminating ~300 pixels per exposure instead of one.
- Hadamard over random masks on eigenvalue grounds, because reconstruction error is H-1 applied to noise, so small eigenvalues amplify it directly.
Free-compute landscape study
2026
Research · machine-readable knowledge base
A machine-readable knowledge base of free-compute offers, with 190 providers screened, 95 verified against primary sources, and every figure labelled measured or estimated.
Pythonschema designprimary-source verification
Full detail
- 190 providers screened, 95 verified against primary sources, 121 free-tier offers catalogued into a normalised queryable base with a regeneration script.
- Comparative architecture teardown of 3 open-source aggregators.
- Every figure labelled measured or estimated; incompatible units never summed; ToS restrictions on aggregation documented.