Skip to content
Snippets Groups Projects
Commit 4411c857 authored by Lionel GUEZ's avatar Lionel GUEZ
Browse files

Polish

parent 51e63056
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env python3
"""This script loads a segmented cf graph in the gt format, iterates
on all of the edges and cost functions and generates the trajectories
as done in MATLAB. Segments (nodes) have a new vertex property called
"traj_prop" that holds the trajectory ID that that segment belongs to. The
output is either an expanded JSON file and/or an edgelist file with
all of the trajectories.
Inputs:
the gt segmented cf graph
Output:
trajectories.json that contains all of the trajectories
"""This script loads the graph of segments, with cost functions and
identifies trajectories.
Inputs: the graph of segments produced by Graph-tool (gt or graphml
format). Output: trajectories as lists of segments and as lists of
instantaneous eddies, in JSon files.
"""
import graph_tool
from os import path
import json
import csv
from graph_tool import util, search
import sys
import numpy as np
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment