-
Notifications
You must be signed in to change notification settings - Fork 1
/
config.py-example
121 lines (105 loc) · 4.58 KB
/
config.py-example
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
## hood - collective neighborhood opinion map generator
##Copyright (C) 2005 Matt Chisholm & Ross Cohen
##This program is free software; you can redistribute it and/or
##modify it under the terms of the GNU General Public License
##as published by the Free Software Foundation, version 2.
##This program is distributed in the hope that it will be useful,
##but WITHOUT ANY WARRANTY; without even the implied warranty of
##MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
##GNU General Public License for more details.
overall_scale = 1.09
blob_radius = 6.0 * overall_scale
blob_adj = 0.95
config = {
'db_host' : 'localhost' ,
#'db_name' : 'hoodtest' ,
'db_name' : 'neighborhood',
'db_user' : '' ,
'db_pass' : '' ,
'city' : 'San Francisco' ,
'state' : 'CA' ,
'font_path' : '/Library/Fonts/Futura.ttc',
'font_size' : 18,
'map_path': 'webpage/map/hoods/',
'geocoder' : 'http://rpc.geocoder.us/service/xmlrpc',
'rss_url' : 'http://www.craigslist.org/sfc/hhh/index.rss',
'html_url' : 'http://www.craigslist.org/sfc/hhh/',
'pidfile' : '/Users/matt/neighborhood_scraper.pid',
'logfile' : '/Users/matt/neighborhood_scraper.log',
'output_format' : 'png',
# rendering knobs
'point_radius' : int(round(4 * overall_scale)),
'blob_radius' : blob_radius,
'blob_outer' : blob_radius + 0.4 * overall_scale, # for antialiasing
'blob_influence' : int(round(blob_radius * 3.5 * overall_scale)),
# receding blobs stuff
'receding_blobs' : False,
'blob_adj' : blob_adj,
'blob_scale' : 0.7 / blob_adj,
'draw_stddev' : False,
'viewer' : 'open', # Mac OS X, try 'eog' on Linux
'show_image' : True,
'neighborhoods' : set(('mission district',
'sunset / parkside',
'pacific heights',
'inner richmond',
'marina / cow hollow',
'noe valley',
'inner sunset / UCSF',
'SOMA / south beach',
'downtown / civic / van ness',
'lower pac hts',
'richmond / seacliff',
'ingleside / SFSU / CCSF',
'russian hill',
'nob hill',
'lower haight',
'castro / upper market',
'north beach / telegraph hill',
'haight ashbury',
'financial district',
'western addition',
'laurel hts / presidio',
'bernal heights',
'excelsior / outer mission',
'hayes valley',
'potrero hill',
'glen park',
'USF / panhandle',
'cole valley / ashbury hts',
'lower nob hill',
'twin peaks / diamond hts',
'bayview',
'west portal / forest hill',
# manual additions
'alamo square',
'chinatown',
'dogpatch',
'dolores park',
'duboce triangle',
'fillmore',
'hunter\'s point',
'japantown',
'tenderloin',
'woodside',
'alamo square / NOPA',
# '',
# '',
)),
'neighborhood_blacklist': ('south lake tahoe',
'sf',
'sf bay area',
'san francisco',
'mendocino coast',
'bay area',
'tahoe city',
'pics',
'seattle',
'tahoe donner',
'north lake tahoe'
'photos',
'lake tahoe',
'mexico',
'squaw valley'),
}
config['citystate'] = ', '+config['city']+' '+config['state']