Added Main environment class and main function

No enum type in py2.

Also I feel like ‘host_send_rate’ looks much cleaner than env.host_send_rate or env.Measurement.host_send_rate

郑韬堃 Taokun (Xander) Zheng

Email: tzheng@caltech.edu
Mobile: 1-626-354-2788

Address:
California Institute of Technology
MSC 1076, Pasadena, CA 91126

On Nov 11, 2014, at 12:53 PM, adbh94 <notifications@github.com> wrote:

> In env.py:
> 
> > +
> > +class MainEnv(simpy.Environment):
> > +    '''The class for main environment for our network sumulator.'''
> > +    HOST_FIELDS = ['host_send_rate',
> > +                   'host_receive_rate',
> > +                  ]
> > +                    
> > +    FLOW_FIELDS = ['flow_send_rate',
> > +                   'flow_receive_rate,
> > +                   'flow_avg_RTT',
> > +                  ]
> > +        
> > +    LINK_FIELDS = ['packet_loss',
> > +                   'buffer_occupancy',
> > +                   'link_rate',
> > +                  ]
> 
> You're enumerating the metrics here... except you're not using an enum... I really think we should have an enum called Measurements containing these parameters.
> 
> —
> Reply to this email directly or view it on GitHub.
>