diff --git a/public/airtable.pkl b/public/airtable.pkl index fa822c7..a337b51 100644 Binary files a/public/airtable.pkl and b/public/airtable.pkl differ diff --git a/public/nongeocoded_members.csv b/public/nongeocoded_members.csv index 62ec5b1..8ff621e 100644 --- a/public/nongeocoded_members.csv +++ b/public/nongeocoded_members.csv @@ -1,3 +1,21 @@ -,Website,Name,Legislation,Address,Membership Status,lat,lon,Phone -0,https://antievictionmap.com/?category=New+York+City,Anti-Eviction Mapping Project,['Statewide Right to Counsel'],,['Endorser'],,, -1,http://civilrighttocounsel.org/about,National Coalition for a Civil Right to Counsel,['Statewide Right to Counsel'],,['Endorser'],,, +,Website,Name,Legislation,Address,Membership Status,lat,lon,Phone,Senate_District,Assembly_District,County,Zip_Code +0,,NY Council of Housing Development Fund Companies,['Winter Eviction Moratorium'],"New York, NY",['Endorser'],,,,,,, +1,https://www.facebook.com/profile.php?id=100064544210388,Solidarity Committee of the Capital District,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","Albany, New York",['Campaign Member'],,,,,,, +2,https://capitaldistrictdsa.org/,Capital District Democratic Socialists of America,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']",P.O. Box 3821 ยท Albany NY 12203,['Campaign Member'],,,,,,, +3,https://www.instagram.com/astoriatenantunion/?hl=en,Astoria Tenants Union,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","Astoria, New York",['Campaign Member'],,,,,,, +4,"https://utalbany.org/housing-for-all/#:~:text=Housing%20for%20All%20is%20a,in%20the%20City%20of%20Albany.",Housing for All Albany,['Statewide Right to Counsel'],"Albany, NY",['Endorser'],,,,,,, +5,https://antievictionmap.com/?category=New+York+City,Anti-Eviction Mapping Project,['Statewide Right to Counsel'],,['Endorser'],,,,,,, +6,https://www.syracusetenantsunion.com/about,Syracuse Tenant Union,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","Syracuse, New York",['Campaign Member'],,,315-308-0130,,,, +7,https://www.instagram.com/rtcwestchester/?hl=en,Westchester Right to Counsel Coalition,['Statewide Right to Counsel'],"Westchester, NY",['Endorser'],,,,,,, +8,https://www.ridgewoodtenantsunion.org/,Ridgewood Tenants Union,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","Ridgewood, Queens, NY",['Coalition Member'],,,732-835-2344,,,, +9,https://www.vocal-ny.org/chapter/syracuse/,VOCAL-NY - Syracuse,['Statewide Right to Counsel'],"Syracuse, NY, USA",['Endorser'],,,718-802-9540,,,, +10,https://longislandactivists.org/,Long Island Activists,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","Long Island, NY",['Campaign Member'],,,,,,, +11,https://buffalo-dsa.org/,Buffalo Democratic Socialists of America,['Statewide Right to Counsel'],"Buffalo, NY",['Endorser'],,,,,,, +12,https://mcah.squarespace.com/,Mamaroneck Coalition for Affordable Housing,"['Winter Eviction Moratorium', 'Statewide Right to Counsel']","Mamaroneck, NY",['Endorser'],,,,,,, +13,https://www.lhvdsa.org/,Lower Hudson Valley Democratic Socialists of America,['Statewide Right to Counsel'],"Yonkers, NY",['Endorser'],,,,,,, +14,https://housingjusticeforall.org/,Housing Justice for All,['Statewide Right to Counsel'],"New York, NY",['Endorser'],,,,,,, +15,https://nylscoalition.org/,New York Legal Services Coalition,['Statewide Right to Counsel'],"New York, NY",['Endorser'],,,315-572-0373 ,,,, +16,https://www.vocal-ny.org/chapter/buffalo/,VOCAL-NY - Buffalo,['Statewide Right to Counsel'],"Buffalo, NY, USA",['Endorser'],,,718-802-9540,,,, +17,http://civilrighttocounsel.org/about,National Coalition for a Civil Right to Counsel,['Statewide Right to Counsel'],,['Endorser'],,,,,,, +18,https://syracusedsa.org/contact/,Syracuse Democratic Socialists of America,['Winter Eviction Moratorium'],"Syracuse, NY",['Endorser'],,,,,,, +19,https://housingcourtanswers.org/,Housing Court Answers,"['Clean Hands', 'Statewide Right to Counsel', 'Defend Right to Counsel', 'Winter Eviction Moratorium']","New York, New York",['Coalition Member'],,,212-962-4795,,,, diff --git a/scripts/members_geocoder.py b/scripts/members_geocoder.py index bc68da9..52a92b0 100644 --- a/scripts/members_geocoder.py +++ b/scripts/members_geocoder.py @@ -196,7 +196,7 @@ def generate_members_info(AIRTABLE_API_KEY, AIRTABLE_APP_KEY, AIRTABLE_TBL_KEY, if not cached_data.empty: # If the address is in the cache, use the cached latitude and longitude - if cached_data.iloc[0]['lat'] != np.nan: + if not np.isnan(cached_data.iloc[0]['lat']): member['lat'] = cached_data.iloc[0]['lat'] member['lon'] = cached_data.iloc[0]['lon'] # Assuming 'long' is the column name member['Senate_District'] = cached_data.iloc[0]['Senate_District'] @@ -212,7 +212,7 @@ def generate_members_info(AIRTABLE_API_KEY, AIRTABLE_APP_KEY, AIRTABLE_TBL_KEY, member['Assembly_District'] = None member['County'] = None member['Zip_Code'] = None - nongeocoded_members = pd.concat([nongeocoded_members,pd.Dataframe([member])], ignore_index=True) + nongeocoded_members = pd.concat([nongeocoded_members,pd.DataFrame([member])], ignore_index=True) print(f"Could not geocode address (cached)") else: