https://github.com/brownvc/deep-synth
Raw File
Tip revision: b800e11290b763b58e7d3b30329769a7b77cd12a authored by kwang-ether on 14 June 2019, 23:53:57 UTC
remove csv
Tip revision: b800e11
room_type.py
from data.house import *

"""
Just filters by room type
A room may have multiple types, all must match
This removes dual function rooms e.g. bedroom+kitchen
"""
def room_type_criteria(types):
    if not isinstance(types, list): types = [types]
    def wrapper(room, _):
        return all(t in types for t in room.roomTypes) and len(room.roomTypes)>0
    return wrapper

back to top