From 0f9a2c1a82bff1b1747202d32a6ae63a7ecae01e Mon Sep 17 00:00:00 2001 From: Mostapha Date: Wed, 17 Feb 2021 17:03:46 -0500 Subject: [PATCH] fix: add support for sensor groups --- honeybee_radiance_folder/folder.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/honeybee_radiance_folder/folder.py b/honeybee_radiance_folder/folder.py index 2e8e3f3..f91e3b1 100644 --- a/honeybee_radiance_folder/folder.py +++ b/honeybee_radiance_folder/folder.py @@ -427,13 +427,18 @@ def scene_files(self, black_out=False, rel_path=True): ) return self._match_files(modifier_files, geometry_files) - def grid_files(self, rel_path=True): + def grid_files(self, rel_path=True, group=None): """Return list of grid files.""" cfg = self._config['GRID'] pattern = cfg['grid_pattern'] - grid_files = self._find_files( - self.grid_folder(full=True), pattern, rel_path - ) + if not group: + grid_files = self._find_files( + self.grid_folder(full=True), pattern, rel_path + ) + else: + grid_files = self._find_files( + os.path.join(self.grid_folder(full=True), group), pattern, rel_path + ) return grid_files def grid_info_files(self, rel_path=True):