visual test improvements: comment non-critical raster-tiff tests, start testing grids, and ignore alpha when comparing agg output to cairo

This commit is contained in:
Dane Springmeyer 2012-11-20 15:08:53 -08:00
parent a10511f6b4
commit 3ce7ae7fc9
70 changed files with 168 additions and 33 deletions

View file

@ -3,33 +3,43 @@
import sys
import mapnik
try:
import json
except ImportError:
import simplejson as json
COMPUTE_THRESHOLD = 16
errors = []
passed = 0
# returns true if pixels are not identical
def compare_pixels(pixel1, pixel2):
def compare_pixels(pixel1, pixel2, alpha=True):
if pixel1 == pixel2:
return False
r_diff = abs((pixel1 & 0xff) - (pixel2 & 0xff))
g_diff = abs(((pixel1 >> 8) & 0xff) - ((pixel2 >> 8) & 0xff))
b_diff = abs(((pixel1 >> 16) & 0xff)- ((pixel2 >> 16) & 0xff))
a_diff = abs(((pixel1 >> 24) & 0xff) - ((pixel2 >> 24) & 0xff))
if(r_diff > COMPUTE_THRESHOLD or
g_diff > COMPUTE_THRESHOLD or
b_diff > COMPUTE_THRESHOLD or
a_diff > COMPUTE_THRESHOLD):
return True
if alpha:
a_diff = abs(((pixel1 >> 24) & 0xff) - ((pixel2 >> 24) & 0xff))
if(r_diff > COMPUTE_THRESHOLD or
g_diff > COMPUTE_THRESHOLD or
b_diff > COMPUTE_THRESHOLD or
a_diff > COMPUTE_THRESHOLD):
return True
else:
return False
if(r_diff > COMPUTE_THRESHOLD or
g_diff > COMPUTE_THRESHOLD or
b_diff > COMPUTE_THRESHOLD):
return True
return False
def fail(actual,expected,message):
global errors
errors.append((message, actual, expected))
# compare two images and return number of different pixels
def compare(actual, expected):
def compare(actual, expected, threshold=0, alpha=True):
global errors
global passed
im1 = mapnik.Image.open(actual)
@ -46,13 +56,30 @@ def compare(actual, expected):
return delta_pixels
for x in range(0,im1.width(),2):
for y in range(0,im1.height(),2):
if compare_pixels(im1.get_pixel(x,y),im2.get_pixel(x,y)):
if compare_pixels(im1.get_pixel(x,y),im2.get_pixel(x,y),alpha=alpha):
diff += 1
if diff != 0:
if diff > threshold: # accept one pixel different
errors.append((diff, actual, expected))
passed += 1
return diff
def compare_grids(actual, expected, threshold=0, alpha=True):
global errors
global passed
im1 = json.loads(open(actual).read())
try:
im2 = json.loads(open(expected).read())
except RuntimeError:
errors.append((None, actual, expected))
return -1
equal = (im1 == im2)
diff = 0
# TODO - real diffing
if not equal:
errors.append((1, actual, expected))
passed += 1
return diff
def summary(generate=False):
global errors
global passed

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-3", "-4", "-5", "-6", "-7", "-8", "-9", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! # $ % & ' ( ) * + ", " ! ", " ! ## $$$$ %%%%% &&&&& '''''' ((((((((( )))))))))) *********** ++++++++++ ", " $ % % &&&&& ''''' ((((((((( ))))))))) ********** ++++++++++ ", " )) ** * ++++++++++ ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-3", "-4", "-5", "-6", "-7", "-8", "-9", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! # $ % & ' ( ) * + ", " $ & * ", "!!!!!!! !!!! !! $$$$$ $$$ $$$$$$$$$$ &&&&&&&&&&&&& &&& ((((((((( ((((((((((( ********* ******** ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&&&&&&&&&& (((((((((((((((((((( ******** ********* ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&& &&&&&&& (((((((((((((((((((( ******** ********* ", " !!!!!! !!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&&&&& & && ( (((((((((((((((((( ****** *********** ", " !!!!!!!!!!! $$$$$$$$$$$$ &&&&&&&&&&& ((((((((((((( *********** ", " !!!!!!!!!!! $$$$$$$$$$$$$ &&&&&&&&&&& ((((((((((((( *********** ", " ! $ $ & * ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-3", "-4", "-5", "-6", "-7", "-8", "-9", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! # $ % & ' ( ) * + ", " $ & * ", "!!!!!!! !!!! !! $$$$$ $$$ $$$$$$$$$$ &&&&&&&&&&&&& &&& ((((((((( ((((((((((( ********* ******** ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&&&&&&&&&& (((((((((((((((((((( ******** ********* ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&& &&&&&&& (((((((((((((((((((( ******** ********* ", " !!!!!! !!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&&&&& & && ( (((((((((((((((((( ****** *********** ", " !!!!!!!!!!! $$$$$$$$$$$$ &&&&&&&&&&& ((((((((((((( *********** ", " !!!!!!!!!!! $$$$$$$$$$$$$ &&&&&&&&&&& ((((((((((((( *********** ", " ! $ $ & * ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-3", "-4", "-5", "-6", "-7", "-8", "-9", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! # $ % & ' ( ) * + ", " $ & * ", "!!!!!!! !!!! !! $$$$$ $$$ $$$$$$$$$$ &&&&&&&&&&&&& &&& ((((((((( ((((((((((( ********* ******** ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&&&&&&&&&& (((((((((((((((((((( ******** ********* ", "!!!!!!!!!!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&& &&&&&&& (((((((((((((((((((( ******** ********* ", " !!!!!! !!!!!!! $$$$$$$$$$$$$$$$$$$$ &&&&&&&& && & && ( (((((((((((((((((( ****** * ********* ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-3", "-4", "-5", "-6", "-7", "-8", "-9", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! # $ % & ' ( ) * + ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !! !! ! !! !!! ! !! !! ! ", " !!!!!!!!!!!! !!!!!!!!!!!!! !!!!!!!!!!!! ", " !!!!!!!!!!!!! !!!!!!!!!!!! !!!!!!!!!!!!! ", " ! !! ! ! !! ! !!! ! ! ", " !!!!!!! !!!!!!! !!!!!!! ", " !!!!!!! !!!!!!! !!!!!!! ", " ! ! ", " ", " ", " ", " !! !! ! !! !! ! ", " !!!!!!!!!!!! !!!!!!!!!!!! ", " !!!!!!!!!!!!! !!!!!!!!!!!!! ", " ! !! ! ! ! !!! ! ! ", " !!!!!!! !!!!!!! ", " !!!!!!! !!!!!!! ", " ! ! ", " ", " ", " ", " !! !! ! !! !!! ! !! !! ! ", " !!!!!!!!!!!! !!!!!!!!!!!!! !!!!!!!!!!!! ", " !!!!!!!!!!!!! !!!!!!!!!!!! !!!!!!!!!!!!! ", " ! !! ! ! !! ! !!! ! ! ", " !!!!!!! !!!!!!! !!!!!!! ", " !!!!!!! !!!!!!! !!!!!!! ", " ! ! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "216", "212", "210", "208", "240", "200", "206", "202", "204"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!! !!!!!!!!!!! ", " ############################################# ", " ############################################# ", " ############################################# ", " ", " ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " '' '' (((((((((( ))))))) ", " ''''''' (((((((((( )))))))) ", " ''''''''' (((((((((( )))))))) ", " '''' '''' )))) )))) ", " ''' ''' ))) )))) ", " '''' '''' )))))))) ", " '''''''' ********** )))))))) ", " ''''''' ********** )))))) ", " ''' ********** ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "216", "212", "210", "208", "240", "200", "206", "202", "204"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!! ", " ############################################# ", " ############################################# ", " ############################################# ", " ", " ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " '' '' (((((((((( ))))))) ", " ''''''' (((((((((( )))))))) ", " ''''''''' (((((((((( )))))))) ", " '''' '''' )))) )))) ", " ''' ''' ))) )))) ", " '''' '''' )))))))) ", " '''''''' ********** )))))))) ", " ''''''' ********** )))))) ", " ''' ********** ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "216", "212", "210", "208", "240", "200", "206", "202", "204"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!!!!!!!!!! !!!!!!!!!!! ", " ############################################# ", " ############################################# ", " ############################################# ", " ", " ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ ", " ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&& ", " '' '' (((((((((( ))))))) ", " ''''''' (((((((((( )))))))) ", " ''''''''' (((((((((( )))))))) ", " '''' '''' )))) )))) ", " ''' ''' ))) )))) ", " '''' '''' )))))))) ", " '''''''' ********** )))))))) ", " ''''''' ********** )))))) ", " ''' ********** ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "212", "210", "132", "208", "206", "200", "202", "204"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!! !!! !!!! !!! !!!! !!! ", " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ", " !!! !!! !!! !!! !!! !!! ", " !!!! !!! !!!! !!! !!!! !!! ", " ", " ### ", " ############################################# ", " ### ", " $$$$ ### % % %%% % % %%% % % ", " $$$$ %%% %%% %%% %%% %%% ", " $$%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", " $$$$ %%%% %%%% %%%% %%%% %%%% ", " ", " ", " & & ", " &&&& ", " ''' &&&&&&&&&& ( (( ", " ''' ''' &&&& (((( ((( ", " ''' ''' &&&& (((( ((( ", " ''' ''''' ((( ((( ", " ''' ''' )))) (((( (((( ", " ' ''' )))) ((( ", " ' )))))))))) ", " )))) ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-3", "-5", "-7", "-9", "-2", "-4", "-6", "-8", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", "!!! ### $$$ %%% &&& ", "!!! #### $$$ %%%% &&&& ", "!!!! #### $$$$ %%% &&&& ", "! # # $ $ % & & ", " ! ' # ( $ ) % * & +", " ", " '' ( ) * ++", " '' (( )) ** +++", " '' (( )) ** +++", " ) ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-2", "-4", "-6", "-7", "-8", "-9", "-3", "-5", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " !!! ## $$ $ %%%&&& ''' ((( ", "!!!!####$$$$$$$$$$$%%%%&&&&'''(((( ", "!!!!####$$$$$$$$$$$%%%%&&& '''(((( ", " ! # $$ $ %% ' ' ( ", " ! # ) $ * % & ' ( +", " ", "))) ) ) ) ++", ")))))))))))))))))))) +++", " ))))))) ))))))))))) +++", " ))))))))))))))))))) +", " ) ) ) ) ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-3", "-5", "-7", "-9", "-2", "-4", "-6", "-8", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " !!! ## # # $$$ $$ %%% && & ", " !!! ############# $$$$$$$$$$$%%%%%%%%%%%%%%&&&&&&&&&&& ", " !!! ############ $$$$$$$$$$ %%%%%%%%%%%%%&&&&&&&&&&& ", " ! ## # # $ $ % % % && & ", " ! ' # ( $ ) % * & + ", " ", " '''' ' ' ( ))) ) ) * +++ ", " ''''''''''''''''' (( ))))))))) )))))) ** ++++", " '''''''' ''''''' ((( )))))))))))))) *** ++++", " '''''''' ''''''' ))))))))))))))) * + ", " ' ' ' ))) ) ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-3", "-5", "-7", "-9", "-2", "-4", "-6", "-8", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", "! ! ## ## $$ $$ %%% % &&& & & ", "!!!!!!!!!! ############# $$$$$$$$$$ %%%%%%%%%%%%%% &&&&&&&&&&&& ", "!!!!!!!!!! ############# $$$$$$$$$$ %%%%%%%%%%%%% &&&&&&&&&&& ", " !! ! ! ## # $$ $ % % % & & ", " ! ' # ( $ ) % * & + ", " ", " ''' ' ' ( ))) ) )) * + + ", " ''''''''''''''''' (( ))))))))))))))) *** ++++ ", " '''''''''''''''' ((( )))))))))))))) *** ++++ ", " '''''''' ''''''' )))))))))))))) * + ", " ''' ' ))) ) ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-3", "-5", "-7", "-9", "-10", "-2", "-4", "-6", "-8"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", "!! ## ## $$ $$ %% % && & & '''' ", "!!!!!!!!!!! ############# $$$$$$$$$$$ %%%%%%%%%%%%%% &&&&&&&&&&&& ''''' ", "!!!!!!!!!!! ############# $$$$$$$$$$ %%%%%%%%%%%%% &&&&&&&&&&& ''''' ", " !! ! ! # ## $ $ %% %% % && ' ", " ! ( # ) $ * % + & ' ", " ", " ((( ( ( ))) ) )) *** * ** ++++ + ++ + + ", " ((((((((((((((((( ))))))))))))))))))) *************** +++++++++ ++++++++++ ", " (((((((((((((((( )))))))) )))))))) ******* ****** ++++++++ ++++++++++ ", " (((((((((((((((( ))))))))))))))))) ************** ++++++++ ++++++++++ ", " ( ( ( ) ) ) ) * * * + + + +++ ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-4", "-6", "-8", "-10", "-1", "-3", "-5", "-7", "-9"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " !! ! ### ## $$ $ %% % % && ", " !!!!!!!!!!! ############ $$$$$$$$$$ %%%%%%%%%%%% &&&&&&&&&& ", " !!!!!!!!!! ########## $$$$$$$$$ %%%%%%%%%%%% &&&&&&&&&& ", " !! ! # # $ $ %% % %% && & ", " ' ! ( # ) $ * % + & ", " ", "''' ' ((( ( (( )))) ) ))) **** * +++ + + ", "'''''''' ''''''' (((((((((((((((((((( ))))))))) ))) ))) ********* *********** ++++++++++++++++++ ", "'''''''' '''''''' ((((((((((((((((((( )))))))) ))))))) ******************** +++++++ +++++++++ ", "'''''''' '''''''' ((((((((((((((((((( )))))))) ))))))) ******************** +++++++++++++++++ ", " ' ' ' ' ( ( ( ( ) ) )) * * * * * + + + ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !! ", " !!! ", " ! !! ", " !!!!!!!!! ", " !!!!!!!!!! ", " !! ", " ", " !!!! ", " !!!!! ", " !!!!! ", " !!! !!! ", " ! !!! ", " !!!!!!!! ", " !!!!!!!! ", " !!!!!! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-6", "-7", "-9", "-10", "-3", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!! ", " !!! ", " !!! ", " ### !!! ", " ### ", " $$$ %%%% ##### &&& ''' !!! ((((((((( )))) ", " $$$ %%% **** +++ ### &&& ''' !!! ((((((( )) ", " $$$ %%% *** +++ &&& ''' !!! (((((((( ))) ", " $$$ %%%% ** ++++ &&& ''' !!! ((((((((( )))) ", " **** +++ ", " !!! ", " !! ", " !!! ", " ! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!! ", " !!! ", " !!! ", " ### !!!! ", " ### ", " $$$ %%% & #### ''' (((( !!! ))))))))) **** ", " $$$ %%%% &&& +++ #### ''' ((( !!! ))))))) ** ", " $$$ %%% &&& +++ ''' ((( !!! )))))))) *** ", " $$$$ %%%% &&& ++++ '''' (((( !!!! ))))))))) **** ", " &&& ++++ ", " !!! ", " !! ", " !!! ", " ! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!! ", " !!! ", " !!! ", " ### !!!! ", " ### ", " $$$$ %%% & #### ''' ((( !!! )))))))) *** ", " $$$ %%% &&& ++++ ### ''' ((( !!! )))))))) *** ", " $$$ %%% &&& ++++ ''' ((( !!! )))))))) *** ", " $$$$ %%% &&& ++++ ''' ((( !!!! ) )))) ) *** ", " &&& ++++ ", " !!! ", " !! ", " !!! ", " ! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!!! ", " !!! ", " !! ", " ### !!!! ", " ### ", " $$$$ %%% & ##### '''' ((( !!!! ))))))))) **** ", " $$ %%% &&& ++++ ### '' ((( !! ))))))) ** ", " $$$ %%% &&& +++ ''' ((( !!! )))))))) *** ", " $$$$ % % &&& ++++ '''' (((( !!!! ))))))))) **** ", " &&& ++++ ", " !!!! ", " !! ", " !!! ", " !!!! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!!! ", " !!! ", " !! ", " ### !!!! ", " ### ", " $$$$ %%% & ##### '''' (((( !!!! ))))))))) **** ", " $$ %%% &&& +++ ### '' ((( !! ))))))) ** ", " $$$ %%% &&& +++ ''' ((( !!! ))))))) ** ", " $$$$ % % &&& ++++ '''' (((( !!!! ))))))))) **** ", " &&&& ++++ ", " !!!! ", " !! ", " !!!! ", " !!!! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!! ", " !!! ", " !!! ", " ### !!!! ", " ### ", " $$$$ %%% & #### '''' (((( !!! )))))))) *** ", " $$ %%% &&&& +++ #### ''' ((( !!! )))))))) *** ", " $$$ %%% &&& +++ '' (( !!! )))))))) *** ", " $$$$ % % &&& ++++ '''' (((( !!!! ))))))))) **** ", " &&&& ++++ ", " !!! ", " !! ", " !!! ", " !! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-3", "-6", "-7", "-9", "-10", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ! ! ", " !!! ", " !!! ", " #### !!! ", " ### ", " $$$$ %%% & #### '''' (((( !!! )))))))) *** ", " $$ %%% &&&& +++ #### ''' ((( !!! )))))))) *** ", " $$$ %%% &&& +++ ''' ((( !!! )))))))) *** ", " $$$$ % % && ++++ '''' (((( !!! ) )))) ) *** ", " &&&& +++ ", " !!! ", " !!! ", " !!! ", " ! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-6", "-7", "-9", "-10", "-3", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!! ", " !!! ", " !!! ", " #### !!! ", " #### ", " $$$$ %%% #### &&& ''' !!! (((((((( )))) ", " $$ %%% **** +++ #### &&& '''' !!! (((((((( )) ", " $$$ %%% *** +++ &&& ''' !!! (((((((( ))) ", " $$$$ % % ** ++++ &&&& '''' !!! ((((((((( )))) ", " **** +++ ", " !!! ", " !! ", " !!! ", " ! ! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-6", "-7", "-9", "-10", "-3", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!!! ", " !!! ", " !! ", " # # !!!! ", " ### ", " $$$$ %%% #### &&& '''' !!!! (((((((( ))) ", " $$ %%% **** +++ ### &&& ''' !! (((((((( ))) ", " $$$ %%% *** +++ &&& ''' !!! (((((((( ))) ", " $$$$ %%%% ** +++++ &&&& '''' !!!! ((((((((( ))) ", " **** +++ ", " !!!! ", " !! ", " !!! ", " !!!! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-8", "-5", "-1", "-2", "-6", "-7", "-9", "-10", "-3", "-4"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !!!! ", " !!! ", " !! ", " #### !!!! ", " ### ", " $$$$ %%%% #### &&& ''' !!!! (((((((( ))) ", " $$ %%% *** +++ #### &&& ''' !! (((((((( ))) ", " $$$ %%% *** +++ &&& ''' !!! (((((((( ))) ", " $$$$ %%%% *** ++++ &&& ''' !!!! (((((((( ))) ", " *** ++++ ", " !!!! ", " !! ", " !!!! ", " !!!! ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-5", "-8", "-1", "-9", "-10", "-3", "-7"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", "! ", "!!!!!!!!!#### $$$$$$ ", "!!!!!!!!!##### $$$$$$$ ", " !! ! ## # $$$$ ", " ", " %%%% %% ", " % %%%%%%%% %%%%%%%% & '", " %%%%%%%% %%%%%%%% ", " %%%%%%%% %%%%%%%% ", " ", "((( ( ))) ", "((((((((((((())))))) ", " (((((((((((( )) ) ", " ( ( ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-7", "-4", "-10", "-1", "-6", "-3", "-8"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " !! ! ## ", "!!!!!!!!!!!$ $$ ############## %% %", " !!!!!!!!!!$$$$$ ############## %%%%", " !! ! $ # # # % ", " ", " &&&& & ''' '' '' ", " & &&&&&&&&&&&&&&&& ' ''''''''''''''", " &&&&&&&&&&&&&&&& ''''''''''''''", " &&&&&&&& &&&&&&& ''''''''''''''", " ", "((( ( ( ( ))) ) ) ) ", "(((((((((((((((((((( ))))))))))))) ", " ((((((( ((((((((((( )))))))))))) ", " ((((((((((((((((((( ) ))) ", " ( ( ( ( ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-5", "-8", "-10", "-1", "-4", "-7", "-3", "-6", "-9"], "data": {}, "grid": [" ", " ", " ", " ", " ", " !!!! ! ! ### # ## $$$$ $ $$ $ $ ", " !!!!!!!!!!!!!!!!! #################$$$$$$$$$ $$$$$$$$$$ ", " !!!!!!!! !!!!!!! ################ $$$$$$$$ $$$$$$$$$$%%%% ", " !!!!!!!! !!!!!!! ######## ####### $$$$$$$$ $$$$$$$$$$%%%%%", " ! ! ! ### # $ $ $ $$$ % ", " ", " &&&& && '''' ' '' ((( (( ", " & &&&&&&&& &&&&&&&&' '''''''''''''''''( (((((((((((((((((((", " &&&&&&&& &&&&&&&& '''''''' ''''''' (((((((((((((((((((", " &&&&&&&& &&&&&&& '''''''' ''''''' (((((((((((((((((((", " ", " ))) ) )) *** * * ++++ + ++ ", " )))))))))))))))))))) ********* ****** +++++++++ ++++++++", " ))))))))))))))))))) ************** ++++++++ ++++++++", " ))))))))))))))))))) *************** ++++++++ ++++++++", " ))) ) ) *** * + + +", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-5", "-8", "-10", "-1", "-4", "-7", "-3", "-6", "-9"], "data": {}, "grid": [" ", " ", " ", " ", " ", " !!! ! ! ### # ## $$$ $ $$ $ $ ", " !!!!!!!!!!!!!!!!! ################ $$$$$$$$$$$$$$$$$$$$%% % ", " !!!!!!!!!!!!!!!! ####### ######## $$$$$$$ $$$$$$$$$$%%%%%%%%%", " !!!!!!!! !!!!!!! ################ $$$$$$$$$$$$$$$$$$$%%%%%%%%", " !!! ! # # # $ $ $ $$$ %% %", " ", " &&& & '''' '' '' ((( ( ", " & &&&&&&&&&&&&&&&& ' '''''''' '''''''' ( ((((((((((((((((((((% ", " &&&&&&&&&&&&&&&& '''''''' ''''''' (((((((((((((((((((( ", " & &&&&&& &&&&&&& '''''''' ''''''' ( (((((((((((((((((( ", " ", " ))) ) ))) *** * ** +++ + + ", " )))))))))))))))))))) *************** ++++++++++++++++++ ", " ))))))))))))))))))) ************** +++++++++++++++++ ", " )))))))) )))))))))) ************** +++++++++++++++++ ", " ))) ) ) *** * +++ ++ ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-2", "-4", "-6", "-8", "-10", "-1", "-3", "-5", "-7", "-9"], "data": {}, "grid": [" ", " ", " ", " ", " ", " !!! ! ! ### # ## $$$ $ $$ %%%% % %% % % ", " !!!!!!!!!!!!!!!!! ################### $$$$$$$$$$$$$$$ %%%%%%%%% %%%%%%%%%% &&& ", " !!!!!!!!!!!!!!!! ######## ######## $$$$$$$ $$$$$$ %%%%%%%% %%%%%%%%%% &&&&&&&&&&", " !!!!!!!!!!!!!!!! ################# $$$$$$$$$$$$$$ %%%%%%%% %%%%%%%%%% &&&&&&&&&", " ! ! ! # # # # $ $ $ % % % %%% & ", " ", " '''' ' ", " ' '''''''' ''''''' ( # ) $ * % + & ", " '''''''''''''''' ", " '''''''' ''''''' ", " ", " (((( ( ((( ))) ) )) *** * ++++ + ++ ", " ((((((((( (((((((((( ))))))))))))))))) *********************+++++++++ ++++++++ ", " (((((((( ((((((((((( )))))))))))))))) ******* ************ ++++++++ +++++++++ ", " (((((((( ((((((((((( )))))))))))))))) ******************** ++++++++ +++++++++ ", " ( ( ( ( ))) ) * * * * * + + + ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-1", "-3", "-5", "-7", "-9", "-2", "-4", "-6", "-8", "-10"], "data": {}, "grid": [" ", " ", " ", " ", " ", "!!! ! ### # ## $$$$ $ $$$ %%%% % &&& & & ", "!!!!!!!! !!!!!!! #################### $$$$$$$$$ $$$ $$$ %%%%%%%%% %%%%%%%%%%% &&&&&&&&&&&&&&&&&& ", "!!!!!!!! !!!!!!!! ################### $$$$$$$$ $$$$$$$ %%%%%%%%%%%%%%%%%%%% &&&&&&& &&&&&&&&& ", "!!!!!!!! !!!!!!!! ################### $$$$$$$$ $$$$$$$ %%%%%%%%%%%%%%%%%%%% &&&&&&&&&&&&&&&&& ", " ! ! ! ! # # # # $ $ $$ % % % % % & & & ", " ", " ", " ! ' # ( $ ) % * & + ", " ", " ", " ", " '''' ' ' ((( ( (( )))) ) ) *** * * ** * +++ + + ", " ''''''''' ''''''' (((((((((((((((((( ))))))))) )))))) ********* ********** +++++++++++++++", " '''''''' '''''''' ((((((((((((((((( )))))))))))))) ******************* +++++++ ++++++", " '''''''' '''''''' (((((((( ((((((( ))))))))))))))) ******************* ++++++++++++++", " ' ' ' ((( ( ( ) ) ) *** ** *** + + + ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!! !! !!! ", " ! !!!!!!!!!!!!!!!! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " !!!! ! !! ", " !!!!!!!!!!!!!!!! ", " !!!!!!!! !!!!!!! ", " !!!!!!!! !!!!!!! ", " ", " ! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " !!!! !! !!! ", " !!!!!!!!!!!!!!!! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " !!!! !! !!! ", " !!!!!!!!!!!!!!!! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! ", " ", " ", " !!!! ! !! ", " !!!!!!!!!!!!!!!! ", " !!!!!!!! !!!!!!! ", " !!!!!!!! !!!!!!! ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! ", " ", " ", " !!!! !! !!! ", " !!!!!!!!!!!!!!!! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ! ", " ", " ", " !!!! !! !!! ", " !!!!!!!!!!!!!!!! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ", " ", " ", " ", " "]}

View file

@ -0,0 +1 @@
{"keys": ["", "-5"], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " !!!! !! !!! ", " !!!!!!!!!!!!!!!! ! ", " !!!!!!! !!!!!!!! ", " !!!!!!!!!!!!!!!! ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": [""], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"keys": [""], "data": {}, "grid": [" ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " "]}

File diff suppressed because one or more lines are too long

View file

@ -6,7 +6,12 @@ mapnik.logger.set_severity(mapnik.severity_type.None)
import sys
import os.path
from compare import compare, summary, fail
from compare import compare, compare_grids, summary, fail
try:
import json
except ImportError:
import simplejson as json
visual_output_dir = "/tmp/mapnik-visual-images"
@ -32,6 +37,7 @@ files = [
{'name': "lines-2", 'sizes': sizes_few_square,'bbox':default_text_box},
{'name': "lines-3", 'sizes': sizes_few_square,'bbox':default_text_box},
{'name': "lines-shield", 'sizes': sizes_few_square,'bbox':default_text_box},
#{'name': "marker-multi-policy", 'sizes':[(600,400)]},
{'name': "simple-E", 'bbox':mapnik.Box2d(-0.05, -0.01, 0.95, 0.01)},
{'name': "simple-NE",'bbox':default_text_box},
{'name': "simple-NW",'bbox':default_text_box},
@ -50,16 +56,18 @@ files = [
{'name': "jalign-auto", 'sizes': [(200, 200)],'bbox':default_text_box},
{'name': "line-offset", 'sizes':[(900, 250)],'bbox': mapnik.Box2d(-5.192, 50.189, -5.174, 50.195)},
{'name': "tiff-alpha-gdal", 'sizes':[(600,400)]},
{'name': "tiff-alpha-raster", 'sizes':[(600,400)]},
{'name': "tiff-alpha-broken-assoc-alpha-gdal", 'sizes':[(600,400)]},
{'name': "tiff-alpha-broken-assoc-alpha-raster", 'sizes':[(600,400)]},
{'name': "tiff-alpha-gradient-gdal", 'sizes':[(600,400)]},
{'name': "tiff-nodata-edge-gdal", 'sizes':[(600,400)]},
{'name': "tiff-nodata-edge-raster", 'sizes':[(600,400)]},
{'name': "tiff-opaque-edge-gdal", 'sizes':[(256,256)]},
{'name': "tiff-opaque-edge-raster", 'sizes':[(256,256)]},
{'name': "tiff-opaque-edge-gdal2", 'sizes':[(600,400)]},
{'name': "tiff-opaque-edge-raster2", 'sizes':[(600,400)]},
# https://github.com/mapnik/mapnik/issues/1520
# commented because these are not critical failures
#{'name': "tiff-alpha-raster", 'sizes':[(600,400)]},
#{'name': "tiff-alpha-broken-assoc-alpha-raster", 'sizes':[(600,400)]},
#{'name': "tiff-nodata-edge-raster", 'sizes':[(600,400)]},
#{'name': "tiff-opaque-edge-raster", 'sizes':[(256,256)]},
]
def render(filename, width, height, bbox, quiet=False):
@ -81,30 +89,62 @@ def render(filename, width, height, bbox, quiet=False):
print "\"%s\" with size %dx%d with agg..." % (filename, width, height),
try:
mapnik.render_to_file(m, actual_agg)
diff = compare(actual_agg, expected)
if not quiet:
if diff > 0:
print '\x1b[31m✘\x1b[0m (\x1b[34m%u different pixels\x1b[0m)' % diff
else:
print '\x1b[32m✓\x1b[0m'
except Exception, e:
sys.stderr.write(e.message + '\n')
fail(actual_agg,expected,str(e.message))
if 'tiff' in actual:
actual_cairo = os.path.join(visual_output_dir, '%s-cairo.png' % actual)
if not quiet:
print "\"%s\" with size %dx%d with cairo..." % (filename, width, height),
try:
mapnik.render_to_file(m, actual_cairo,'ARGB32')
diff = compare(actual_cairo, expected)
if not os.path.exists(expected):
# generate it on the fly
fail(actual_agg,expected,None)
else:
diff = compare(actual_agg, expected, threshold=1, alpha=True)
if not quiet:
if diff > 0:
print '\x1b[31m✘\x1b[0m (\x1b[34m%u different pixels\x1b[0m)' % diff
else:
print '\x1b[32m✓\x1b[0m'
except Exception, e:
sys.stderr.write(e.message + '\n')
fail(actual_agg,expected,str(e.message))
if 'tiff' in actual or 'marker' in actual:
actual_cairo = os.path.join(visual_output_dir, '%s-cairo.png' % actual)
if not quiet:
print "\"%s\" with size %dx%d with cairo..." % (filename, width, height),
try:
mapnik.render_to_file(m, actual_cairo,'ARGB32')
if not os.path.exists(expected):
# generate it on the fly
fail(actual_cairo,expected,None)
else:
# cairo and agg differ in alpha for reasons unknown, so don't test it for now
diff = compare(actual_cairo, expected, threshold=1, alpha=False)
if not quiet:
if diff > 0:
print '\x1b[31m✘\x1b[0m (\x1b[34m%u different pixels\x1b[0m)' % diff
else:
print '\x1b[32m✓\x1b[0m'
except Exception, e:
sys.stderr.write(e.message + '\n')
fail(actual_cairo,expected,str(e.message))
if True:
expected_grid = os.path.join(dirname, "grids", '%s-%d-reference.json' % (filename, width))
actual_grid = os.path.join(visual_output_dir, '%s-grid.json' % actual)
if not quiet:
print "\"%s\" with size %dx%d with grid..." % (filename, width, height),
try:
grid = mapnik.Grid(m.width,m.height)
mapnik.render_layer(m,grid,layer=0)
utf1 = grid.encode('utf',resolution=4)
open(actual_grid,'wb').write(json.dumps(utf1))
if not os.path.exists(expected_grid):
# generate it on the fly
fail(actual_grid,expected_grid,None)
else:
diff = compare_grids(actual_grid, expected_grid, threshold=1, alpha=False)
if not quiet:
if diff > 0:
print '\x1b[31m✘\x1b[0m (\x1b[34m%u different pixels\x1b[0m)' % diff
else:
print '\x1b[32m✓\x1b[0m'
except Exception, e:
sys.stderr.write(e.message + '\n')
fail(actual_grid,expected,str(e.message))
return m
if __name__ == "__main__":
@ -132,4 +172,4 @@ if __name__ == "__main__":
m = render(config['name'], size[0], size[1], config.get('bbox'), quiet=quiet)
mapnik.save_map(m, os.path.join(dirname, 'xml_output', "%s-out.xml" % config['name']))
summary(generate=False)
summary(generate=True)