Attempt to refactor a bit of context, new count transform that counts the calls, new bonobo.structs package with basic data structures, removal of blessings.
This commit is contained in:
@ -4,6 +4,7 @@ import os
|
||||
from bonobo import Tee, JsonWriter, Graph, get_examples_path
|
||||
from bonobo.ext.opendatasoft import OpenDataSoftAPI
|
||||
|
||||
from colorama import Fore, Style
|
||||
try:
|
||||
import pycountry
|
||||
except ImportError as exc:
|
||||
@ -36,7 +37,7 @@ def filter_france(row):
|
||||
|
||||
|
||||
def display(row):
|
||||
print(t.bold(row.get('name')))
|
||||
print(Style.BRIGHT, row.get('name'), Style.RESET_ALL, sep='')
|
||||
|
||||
address = list(
|
||||
filter(
|
||||
@ -47,10 +48,10 @@ def display(row):
|
||||
)
|
||||
)
|
||||
|
||||
print(' - {}: {address}'.format(t.blue('address'), address=', '.join(address)))
|
||||
print(' - {}: {links}'.format(t.blue('links'), links=', '.join(row['links'])))
|
||||
print(' - {}: {geometry}'.format(t.blue('geometry'), **row))
|
||||
print(' - {}: {source}'.format(t.blue('source'), source='datanova/' + API_DATASET))
|
||||
print(' - {}address{}: {address}'.format(Fore.BLUE, Style.RESET_ALL, address=', '.join(address)))
|
||||
print(' - {}links{}: {links}'.format(Fore.BLUE, Style.RESET_ALL, links=', '.join(row['links'])))
|
||||
print(' - {}geometry{}: {geometry}'.format(Fore.BLUE, Style.RESET_ALL, **row))
|
||||
print(' - {}source{}: {source}'.format(Fore.BLUE, Style.RESET_ALL, source='datanova/' + API_DATASET))
|
||||
|
||||
|
||||
graph = Graph(
|
||||
|
||||
136
bonobo/examples/datasets/fablabs.txt
Normal file
136
bonobo/examples/datasets/fablabs.txt
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user