Bug #1059
GCTAModelBackground::write() appends temporal model
| Status: | Closed | Start date: | 01/06/2014 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assigned To: | % Done: | 100% | ||
| Category: | - | |||
| Target version: | - | |||
| Duration: |
Description
Currently an .xml-file containing a GCTAModelBackground (created with GModels::save) cannot be read in properly. This is due to an error in GCTAModelBackground::write() where an empty temporal model gets appended to the xml-file. The problem is very easy to solve: line 843 in GCTAModelBackground.cpp has to be removed.
if (temporal() != NULL) src->append(GXmlElement("temporalModel"));
Recurrence
No recurrence.
History
#1
Updated by Knödlseder Jürgen over 12 years ago
- Assigned To set to Knödlseder Jürgen
- % Done changed from 0 to 10
Okay, I wanted to be general, but this needs a little be more thinking. Going to remove this for the moment as you suggest ...
#2
Updated by Knödlseder Jürgen over 12 years ago
- Status changed from New to Feedback
- % Done changed from 10 to 100
Now in devel. Please check if it’s working for you.
#3
Updated by Mayer Michael over 12 years ago
Yes, it works - thanks. In GModelSky, we also only read the spatial and the spectral part. We could think about adding a GModelTemporalConst to all models in their respective write() method, but I guess for now this won’t be used.
#4
Updated by Knödlseder Jürgen over 12 years ago
- Status changed from Feedback to Closed
In fact, the idea would be to write the temporal component if it differs from a standard const unity component. This would conserve compatibility but allow for flexibility once we implement specific temporal models.