Skip to content

3 Automate the generation of visually matching node-edge graph programs from hand-drawn sketches by leveraging vision-language models and differential evolution, combining visual input with mathematical constraints to guide program search.

Notifications You must be signed in to change notification settings

zzigak/Pen2Graph

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 

Repository files navigation

Pen2Graph

This project was done as a final project in CS 6172 at Cornell University. It automates the generation of visually matching node-edge graph programs from hand-drawn sketches by leveraging vision-language models and differential evolution, combining visual input with mathematical constraints to guide program earch.

Screenshot 2025-01-08 at 04 07 11

Final Project Report

Overview

The Pen2Graph pipeline takes as input:

  • An image of a hand-drawn sketch of a node-edge graph (visual constraint).
  • A specification describing the graph's connectivity (mathematical constraint).

Using these inputs, the system:

  1. Generates a parametrized program (e.g., in Matplotlib) via a vision-language model (VLM).
  2. Optimizes the program's parameters using differential evolution to produce a rendering that visually matches the input sketch.

Sample Results

Hand-drawn to program

2

Synthetic to program

1

About

3 Automate the generation of visually matching node-edge graph programs from hand-drawn sketches by leveraging vision-language models and differential evolution, combining visual input with mathematical constraints to guide program search.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published