Skip to content

Commit

Permalink
Merge 92c6386 into 29c44c2
Browse files Browse the repository at this point in the history
  • Loading branch information
chriswmackey committed Feb 8, 2019
2 parents 29c44c2 + 92c6386 commit 27839b6
Show file tree
Hide file tree
Showing 21 changed files with 3,420 additions and 1,469 deletions.
13 changes: 13 additions & 0 deletions ladybug/comfort/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# coding=utf-8
"""Module for computing thermal comfort.
Properties:
SOLARCALSPLINES: A dictionary with two keys: 'standing' and 'seated'.
Each value for these keys is a 2D matrix of projection factors
for human geometry. Each row refers to an degree of azimuth and each
colum refers to a degree of altitude.
"""

from ._loadmannequin import load_solarcal_splines

SOLARCALSPLINES = load_solarcal_splines()
23 changes: 23 additions & 0 deletions ladybug/comfort/_loadmannequin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# coding=utf-8
"""Load data that accounts for human geometry.
This includes mannequin geometry and solarcal splines.
"""

from ..futil import csv_to_num_matrix

from os.path import dirname, abspath
import inspect


def load_solarcal_splines():
try:
cur_dir = dirname(abspath(inspect.getfile(inspect.currentframe())))
solarcal_splines = {
'seated': csv_to_num_matrix(cur_dir + '/mannequindata/seatedspline.csv'),
'standing': csv_to_num_matrix(cur_dir + '/mannequindata/standingspline.csv')}
except IOError:
solarcal_splines = {}
print ('Failed to import projection factor splines from CSV.'
'\nA simpler interoplation method for Solarcal will be used.')
return solarcal_splines
62 changes: 0 additions & 62 deletions ladybug/comfort/comfortmodel.py

This file was deleted.

16 changes: 16 additions & 0 deletions ladybug/comfort/datacollection/_base.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# coding=utf-8
"""Comfort datacollection base object."""


class ComfortDataCollection(object):
"""Thermal comfort datacollection base class."""
_model = None

def __init__(self):
self._calc_length = 0
self._is_computed = False

@property
def comfort_model(self):
"""Return the name of the model to which the comfort datacollection belongs."""
return self._model

0 comments on commit 27839b6

Please sign in to comment.