Optimization of Occupant-Centric Control algorithms

Published: 31 March 2022| Version 1 | DOI: 10.17632/ktts6spgbz.1
Mohamed Ouf


This dataset includes a Python script for optimizing the configurations of occupant-centric control algorithms embedded within an EnergyPlus model.


Steps to reproduce

At first, the required packages were installed and called from their sources. Then, the working directory is defined, and the EnergyPlus directory with the executable file is provided to the code. Based on the Pymoo package instruction, the optimization problem has to be structured like a class. One of the class components initializes the optimization criteria such as number of variables, number of objectives, the boundaries of variables, etc. The second component of the class is the simulation model developed for this paper's purpose. The path to "idf" file and weather file (epw) is passed to the code at this stage. After that, the variables (building design variables/ OCC configurational variables) which are selected based on sensitivity analysis results have to be defined with their applicable ranges. The code replaces the variables in the "idf" file with the assigned value from the optimization algorithm selection process at each simulation loop. Then, the code creates multiple identical idfs and passes them through the simulation program (EP) along with weather files. The multi-core processing is implemented to speed up the simulation process. The idf and weather files split based on the number of cores passed to the model. In this model, high-performance computing (HPC) is implemented to handle multicore processing. The number of cores passes to the code by the "Ncores=int(sys.argv[1])" command. Results of the simulation are stored in multiple arrays. At the end of one loop of the process, the average of each array will be passed to the optimization algorithm. According to the termination criteria, the algorithm will decide to terminate the process to continue to create a new set of variables. The last part of the code is the genetic algorithm setting section. At this stage, the parameters and characteristics of the selected GA method are passed to the GA model to run the optimization algorithm.


Concordia University


Building Engineering