#!/usr/bin/env python # coding: utf-8 # In[1]: get_ipython().run_line_magic('load_ext', 'autoreload') get_ipython().run_line_magic('autoreload', '2') from synthpop.recipes.starter2 import Starter from synthpop.synthesizer import synthesize_all, enable_logging import os import pandas as pd #enable_logging() # In[2]: def synthesize_counties(counties): for county in counties: starter = Starter(os.environ["CENSUS"], "CA", county) synthesize_all(starter) get_ipython().run_line_magic('time', 'hh = synthesize_counties(["Santa Clara County", "Solano County", "San Mateo County", "Marin County", "San Francisco County", "Napa County", "Sonoma County", "Contra Costa County", "Alameda County"])') # In[4]: starter = Starter(os.environ["CENSUS"], "CA", "Santa Clara County") # In[5]: ind = pd.Series(["06", "085", "508203", "3"], index=["state", "county", "tract", "block group"]) synthesize_all(starter, indexes=[ind]) # In[ ]: