Automated Python script for Lehigh University Industrial Training and Assessment Center
This tutorial is designed for Mechanical Engineering people with zero programming knowledge.
Of course, you need to install Microsoft Office. https://confluence.cc.lehigh.edu/display/LKB/Windows+or+macOS%3A++Download+and+Install+Office+365
Install homebrew thenbrew install --cask visual-studio-code anaconda
LibreOffice compatibility is not guaranteed.
conda create -n iac python=3.8
conda activate iac
conda install json5 numpy pandas openpyxl requests
conda install -c conda-forge python-docx docxcompose easydict latex2mathml num2words pgeocode
pip install python-docx-replace meteostat
conda always has the highest priority. If not available, install packages from conda-forge. Don't install from pip unless you have to, otherwise there might be dependency issue.
Go to Extensions(Ctrl+Shift+X), install Python (from Microsoft) and JSON5 syntax (from mrmlnc).
Press Ctrl+Shift+P, search Python: Select Interpreter and select the iac environment you just created.
conda remove --name iac --all
Is it suggested to work on a copy of this reposiotry when generating an IAC report.
For your convenience, download the main branch from this link: https://codeload.github.com/LehighIAC/IAC-Automation/zip/refs/heads/main , then use VS Code to open the folder.
- Edit Energy Charts.xlsx. Selectfuel type,fuel unitandstart month, then edit raw data (if copying from other spreadsheet, copy values only). The formatting is fully automatic and shouldn't be touched.
- Save the workbook as Web Page (.htm)format in the same directory. DO NOT change the filename, all images will be kept inEnergy Charts.fldfolder. Currently this is the only stable way to save all charts as images.
- Run Utility.pyto extract energy usage data from the spreadsheet.
- Edit .json5database of any specific recommendation. Make sure the data type is matching the description.
- Run the corresponding .pyfile. The output will be saved inRecommendationsdirectory. Follow the instructions of the script if there's anything you need to adjust manually.
- No requirement for filename, as long as it's .docx
- Doesn't matter if the file is made from Python template, Excel template, or by hand. Please break links if you used Excel templates.
- The title text should always be "Recommendation x: Title" or "Additional Recommendation x: Title". Case insensitive. In outline view the title should always be Level 1.
- If there's any other type of energy savings, the unit should be MMBtu.
- All subtitles, such as "Recommend Actions", "Anticipated Savings" should always be body text in outline view. Otherwise the automatic table of contents might be broken.
- In rare cases, some .docx files are actually wrapped legacy .doc file (pre Word 2000) and is not supported by this tool. Please copy and paste everything to a new blank .docx file.
- Fill required plant information in Compiler.json5.
- Fill other gathered information in Report/Description.docx
- Copy all recommendation documents(if you have any from other sources) into Recommendationsdirectory.
- Run Compiler.pyto compile the final report.
- Ctrl+A then F9 to refresh ToC, tables and figures, you need to do it twice.
- Install Air-Fuel Ratio Controller [rebate]
- Recover Exhaust Gas Heat [rebate]
- Use Compressor Exhaust to Heat during Winter Months
- Install VFD on Existing Air Compressor [rebate]
- Draw Compressor Intake Air from Outside
- Install New Air Compressor with VFD [rebate]
- Reduce Compressor Set Pressure
- Repair Leaks in Compressed Air Lines
- Install Air Curtain [rebate]
- Insulate Bare Equipemnt
- Programmable Thermostat (based on degree hours)
- Replace Old HVAC Units [rebate]
- Install Motion Sensor [rebate]
- Switch to LED lighting [rebate](supports any number of areas)
- Install Industrial Fans to Improve Air Circulation
- Replace Cogged V-Belts
- Install VFD on Electric Motor [rebate]
- Negotiate Utility Charge
- Install Solar Panel (fully automated using PVWatts API)
