The equivalent periodical costs (ep_costs) are not defined by the oemof community, you can use them however you want. The calculations you find in some examples are just examples. Just keep in mind that these costs are related to the installed capacity represented by the investment variable. Therefore you can use it for all costs related to the installed capacity (capital_costs, fixed_operational_costs,…). For operational costs (OPEX) you should use the `variable_costs attribute because these costs are related to the flow variable (usage of the device).
energysystem.add(solph.Transformer(
label="P2G",
inputs={bel: solph.Flow()},
outputs={bgas: solph.Flow(variable_costs=your_variable_costs)},
conversion_factors={bgas: 0.58},
investment=solph.Investment(ep_costs=your_fixed_costs)))
I do not understand how you want to consider variable costs (cost that depend on the usage of the device) for the future (next 20 years). If you want you can estimate these costs and add them to the fixed costs but this is quit unusual.