(self)
convert lists and dictionaries that are useful for users to
        np vectors that are usable by machines
convert lists and dictionaries that are useful for users to
        np vectors that are usable by machines
convert lists and dictionaries that are useful for users to np vectors that are usable by machines
def _convert_types(self):
        """
        convert lists and dictionaries that are useful for users to
        np vectors that are usable by machines

        """
        self.fars = np.array(self.fars)
        self.parking_rates = np.array([self.parking_rates[use] for use in self.uses])
        self.res_ratios = {}
        assert len(self.uses) == len(self.residential_uses)
        for k, v in self.forms.items():
            self.forms[k] = np.array([self.forms[k].get(use, 0.0) for use in self.uses])
            # normalize if not already
            self.forms[k] /= self.forms[k].sum()
            self.res_ratios[k] = pd.Series(self.forms[k])[self.residential_uses].sum()
        self.costs = np.transpose(np.array([self.costs[use] for use in self.uses]))
def _convert_types ( self ) : self . fars = np . array ( self . fars ) self . parking_rates = np . array ( [ self . parking_rates [ use ] for use in self . uses ] ) self . res_ratios = { } assert len ( self . uses ) == len ( self . residential_uses ) for k , v in self . forms . items ( ) : self . forms [ k ] = np . array ( [ self . forms [ k ] . get ( use , 0.0 ) for use in self . uses ] ) # normalize if not already self . forms [ k ] /= self . forms [ k ] . sum ( ) self . res_ratios [ k ] = pd . Series ( self . forms [ k ] ) [ self . residential_uses ] . sum ( ) self . costs = np . transpose ( np . array ( [ self . costs [ use ] for use in self . uses ] ) )