Blame view

python/network_dpy.py 737 Bytes
a2c755c8   Jiabing Li   start new network...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
  # -*- coding: utf-8 -*-
  """
  Created on Sat Jan 19 2018
  
  @author: Jiabing
  """
  
  import struct
  import numpy as np
  import scipy as sp
  import networkx as nx
  import matplotlib.pyplot as plt
  import math
  
  class Point:
         def __init__(self, x, y, z, radius):
             self.x = x
             self.y = y
             self.z = z
             self.r = radius
                        
              
  class Fiber:
         def __init__(self, fiber_idx,point_idx):     
             self.fidx = fiber_idx
             self.pidx = point_idx
             
             
  
  class Node:
          def __init__(self, point_idx, fidx):
              self.pidx= point_idx
              self.fidx = fidx
              
              
  #class NWT:
      
  #class network(point, Fiber, Node):