Skip to content

Instantly share code, notes, and snippets.

View gregmacfarlane's full-sized avatar

Greg Macfarlane gregmacfarlane

View GitHub Profile
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@gregmacfarlane
gregmacfarlane / LinkTablesToOSMConverter.java
Created May 6, 2022 15:15
Generate an OSM PBF from link and node csv tables
package beam.utils;
import com.conveyal.osmlib.Node;
import com.conveyal.osmlib.OSM;
import com.conveyal.osmlib.Way;
import com.univocity.parsers.common.record.Record;
import com.univocity.parsers.csv.CsvParser;
import com.univocity.parsers.csv.CsvParserSettings;
import org.matsim.core.utils.misc.Counter; // This creates a geometric counter that helped me keep track of things, but isn't necessary
import org.slf4j.Logger;