You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am about to submit a PR to add FunctionData, a better way to represent cost functions, to InfrastructureSystems. I will have adapted the existing HDF serialization/deserialization code for certain types of FunctionData, but FunctionData can represent more cost functions than the existing data structures, so more serialization/deserialization routines will need to be implemented in the future — for instance, something to handle polynomials of arbitrary degree, which might look like
function transform_array_for_hdf(data::Vector{PolynomialFunctionData})
coeffs = data .|> get_coefficients .|> collect
return cat((hcat(([a, b] for (a, b) in coeff)...) for coeff in coeffs)...; dims=3)
end
This would also be a good opportunity to clean up the code duplication that exists between the various methods of transform_array_for_hdf, etc.
The text was updated successfully, but these errors were encountered:
I don't think we intend to support arbitrary function data for MarketBid Cost since the markets only accept PWL data in very specific formats. There is no need no serialize deserialize arbitrary polynomials.
The engineering cost of this solution might be larger than the benefits.
I did some rewriting of HDF (de)serialization and I think I'm happy with where it is now, currently no need for something this drastic. Closing for now.
I am about to submit a PR to add
FunctionData
, a better way to represent cost functions, to InfrastructureSystems. I will have adapted the existing HDF serialization/deserialization code for certain types of FunctionData, but FunctionData can represent more cost functions than the existing data structures, so more serialization/deserialization routines will need to be implemented in the future — for instance, something to handle polynomials of arbitrary degree, which might look likeThis would also be a good opportunity to clean up the code duplication that exists between the various methods of
transform_array_for_hdf
, etc.The text was updated successfully, but these errors were encountered: