# Epw file created with DF gives error

**URL:** <https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404>\
**Category:** dragonfly\
**Tags:** energy\
**Created:** [August 31, 2022, 9:44am UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404 "2022-08-31T09:44:46Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Erikbeeren](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/erikbeeren/32/8868_2.png) [@Erikbeeren](https://discourse.ladybug.tools/u/Erikbeeren)\
**Post date:** [August 31, 2022, 9:44am UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/1 "2022-08-31T09:44:46Z")

</div>

Hi @chris,

I used the “DF create EPW” to create new EPW files. The new files work perfectly with “LB import EPW”.  
When I compare the data of the old file with the new files everything seems to be correct.

 ![afbeelding](https://discourse.ladybug.tools/uploads/default/original/3X/6/4/646c1ab63e9ac4ae7fe454c95892b0b61ff30db7.png)

However when I use the new file for energy simulation it gives me a fatal error with the following error message:

> \*\* Severe \*\* Invalid Date info in Weather Line  
> \*\* ~~~ \*\* Entire Data Line=2001.0,1,1,1,0,?9?9?9?9E0?9?9?9?9?9?9?9?9?9?9?9?9?9?9?9_9_9?9?9?9,1.7,-2.3,73.0695807036,100360.0,9999,9999,276.6,0.0,0.0,0.0,0.0,0,0,9999,150.0,8.0,8.0,8.0,9999,99999,9,999999999,999,999,999,99,999,999,99  
> \*\* Fatal \*\* Error in Reading Weather Data  
> …Summary of Errors that led to program termination:  
> … Reference severe error count=1  
> … Last severe error=Invalid Date info in Weather Line  
> \*\*\*\*\*\*\*\*\*\*\*\*\* Warning: Node connection errors not checked - most system input has not been read (see previous warning).  
> \*\*\*\*\*\*\*\*\*\*\*\*\* Fatal error – final processing. Program exited before simulations began. See previous error messages.
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* ===== Recurring Error Summary =====  
> \*\*\*\*\*\*\*\*\*\*\*\*\* The following recurring error messages occurred.
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* Warning \*\* Temperature out of range [-100. to 200.] (PsyPsatFnTemp)  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* This error occurred 1 total times;  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* during Warmup 0 times;  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* during Sizing 1 times.  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* Max=7947.708252 C Min=7947.708252 C

To create the new file I used the headers of the original IWEC file in the following way:

 ![afbeelding](https://discourse.ladybug.tools/uploads/default/original/3X/f/a/fae419eeefa508579b00abcdaf75aa9b76b1b523.png)

[new EPW.7z](https://discourse.ladybug.tools/uploads/short-url/vFKYl6KL3USzNEjMVpu4AHStU7k.7z) (317.6 KB)  
[NLD\_Amsterdam.062400\_IWEC.zip](https://discourse.ladybug.tools/uploads/short-url/9qUNmx5RAYJzWTtBD2c43qmfXUo.zip) (223.4 KB)

---

<div class="post-metadata">

**Author:** ![chris](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/chris/32/10179_2.png) [@chris](https://discourse.ladybug.tools/u/chris)\
**Post date:** [August 31, 2022, 3:31pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/2 "2022-08-31T15:31:01Z")

</div>

Thanks for reporting, @Erikbeeren ,

It looks like the issue is because we’re writing the year as a float value (2001.0) instead of an integer value (2001). I’ll see if I can push an automated fix shortly but, in the meantime, you should be able to make a simulate-able EPW if you disconnect the `_model_year_` from the component:

![image](https://discourse.ladybug.tools/uploads/default/original/3X/8/f/8fbcf6ffee594fc4a22ee986637befd6897f0dab.png)

---

<div class="post-metadata">

**Author:** ![Erikbeeren](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/erikbeeren/32/8868_2.png) [@Erikbeeren](https://discourse.ladybug.tools/u/Erikbeeren)\
**Post date:** [September 1, 2022, 7:21am UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/3 "2022-09-01T07:21:44Z")

</div>

Hi @chris,

Thank you for the quick reply. I tried to generate an EPW file without model year input but still the simulation stops. Now it gives me the following message:

> \*\* Severe \*\* Reading Weather Data Line, Invalid Date, Year=2017, Month=2, Day=31  
> \*\* Fatal \*\* Program terminates due to previous condition.  
> …Summary of Errors that led to program termination:  
> … Reference severe error count=1  
> … Last severe error=Reading Weather Data Line, Invalid Date, Year=2017, Month=2, Day=31
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* ===== Recurring Error Summary =====  
> \*\*\*\*\*\*\*\*\*\*\*\*\* The following recurring error messages occurred.
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* Warning \*\* Temperature out of range [-100. to 200.] (PsyPsatFnTemp)  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* This error occurred 1 total times;  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* during Warmup 0 times;  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* during Sizing 1 times.  
> \*\*\*\*\*\*\*\*\*\*\*\*\* \*\* ~~~ \*\* Max=7947.708252 C Min=7947.708252 C
> 
> * * *
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* ===== Final Error Summary =====  
> \*\*\*\*\*\*\*\*\*\*\*\*\* The following error categories occurred. Consider correcting or noting.  
> \*\*\*\*\*\*\*\*\*\*\*\*\* Nominally Unused Constructions  
> \*\*\*\*\*\*\*\*\*\*\*\*\* …The nominally unused constructions warning is provided to alert you to potential conditions that can cause  
> \*\*\*\*\*\*\*\*\*\*\*\*\* …extra time during simulation. Each construction is calculated by the algorithm indicated in the HeatBalanceAlgorithm  
> \*\*\*\*\*\*\*\*\*\*\*\*\* …object. You may remove the constructions indicated (when you use the DisplayExtraWarnings option).
> 
> * * *
> 
> \*\*\*\*\*\*\*\*\*\*\*\*\* EnergyPlus Warmup Error Summary. During Warmup: 0 Warning; 0 Severe Errors.  
> \*\*\*\*\*\*\*\*\*\*\*\*\* EnergyPlus Sizing Error Summary. During Sizing: 4 Warning; 0 Severe Errors.  
> \*\*\*\*\*\*\*\*\*\*\*\*\* EnergyPlus Terminated–Fatal Error Detected. 6 Warning; 1 Severe Errors; Elapsed Time=00hr 00min 0.18sec
> 
> Runtime error (PythonException): \*\* Fatal \*\* Program terminates due to previous condition.
> 
> Traceback:  
> line 292, in script

[energie.7z](https://discourse.ladybug.tools/uploads/short-url/b8c1h1XxeMGcECEhYDtYfV5Ljl4.7z) (315.3 KB)

---

<div class="post-metadata">

**Author:** ![chris](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/chris/32/10179_2.png) [@chris](https://discourse.ladybug.tools/u/chris)\
**Post date:** [September 1, 2022, 7:37pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/4 "2022-09-01T19:37:50Z")

</div>

Hey @Erikbeeren ,

You are right that there was another bug beyond what I stated above. I just pushed a fix for everything:

> <https://github.com/ladybug-tools/dragonfly-grasshopper/pull/228>

You can get the fix with the LB Versioner now. I tested it with E+ to be sure it works but just let me know if you hit any hiccups.

---

<div class="post-metadata">

**Author:** ![Erikbeeren](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/erikbeeren/32/8868_2.png) [@Erikbeeren](https://discourse.ladybug.tools/u/Erikbeeren)\
**Post date:** [September 5, 2022, 1:09pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/5 "2022-09-05T13:09:30Z")

</div>

Hi @chris,

Now it is working! 🙂

---

<div class="post-metadata">

**Author:** ![jeiv](https://discourse.ladybug.tools/letter_avatar_proxy/v4/letter/j/8edcca/32.png) [@jeiv](https://discourse.ladybug.tools/u/jeiv)\
**Post date:** [February 27, 2024, 2:56pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/6 "2024-02-27T14:56:37Z")

</div>

Hello @chris, LB cannot read the new epw created with DF, any idea?

 ![image](https://discourse.ladybug.tools/uploads/default/original/3X/6/8/6888cf5b0b12a18a9a11a5f9070260c3e18bbcb5.jpeg)

1. Solution exception:invalid literal for float(): None

I only changed location from first epw  
Thanks

---

<div class="post-metadata">

**Author:** ![Erikbeeren](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/erikbeeren/32/8868_2.png) [@Erikbeeren](https://discourse.ladybug.tools/u/Erikbeeren)\
**Post date:** [February 28, 2024, 1:44pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/7 "2024-02-28T13:44:57Z")

</div>

I cannot determine what is going wrong with only this information. Did you save it as a .epw?

---

<div class="post-metadata">

**Author:** ![chris](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/chris/32/10179_2.png) [@chris](https://discourse.ladybug.tools/u/chris)\
**Post date:** [March 22, 2024, 3:04am UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/8 "2024-03-22T03:04:15Z")

</div>

I can’t recreate it on my end, @jeiv .

Here is a sample file that is running successfully on my end:

 ![image](https://discourse.ladybug.tools/uploads/default/original/3X/9/5/9519029a59da14b7425fe8ebabb1fbef7dc0c9c8.png)

[create\_epw\_from\_epw.gh](https://discourse.ladybug.tools/uploads/short-url/wo007WvSPxVZknicXqJOEWCdanA.gh) (31.2 KB)

---

<div class="post-metadata">

**Author:** ![mchabasset](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/mchabasset/32/31867_2.png) [@mchabasset](https://discourse.ladybug.tools/u/mchabasset)\
**Post date:** [May 25, 2026, 8:26am UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/10 "2026-05-25T08:26:44Z")

</div>

> [@chris](#):
>
> g beyond what I stated above. I jus

Hi @chris,  
I think that the correction is not working or has not been included in the new version of Ladybug Tools.  
I get this error when I try to create a new EPW file with the “DF Create EPW” component.

 ![image](https://discourse.ladybug.tools/uploads/default/original/3X/a/7/a7e510f506de530d67e725d7a3d240c3d8ffe04a.png)

 ![image](https://discourse.ladybug.tools/uploads/default/original/3X/e/a/eaf13a7a2e68e1b03804daf71bf392b026e05136.png)

---

<div class="post-metadata">

**Author:** ![chris](https://discourse.ladybug.tools/user_avatar/discourse.ladybug.tools/chris/32/10179_2.png) [@chris](https://discourse.ladybug.tools/u/chris)\
**Post date:** [May 25, 2026, 6:35pm UTC](https://discourse.ladybug.tools/t/epw-file-created-with-df-gives-error/19404/11 "2026-05-25T18:35:26Z")

</div>

Thanks, @mchabasset ,

It was a bug that only affected the month field of the last item in the EPW. I fixed it here:

> <https://github.com/ladybug-tools/ladybug/pull/655>

The fix should be available via the LB Versioner in an hour or so.
