kzl / decision-transformer

Official codebase for Decision Transformer: Reinforcement Learning via Sequence Modeling.
MIT License
2.33k stars 440 forks source link

Bug in state and action prediction #53

Open ezhang7423 opened 1 year ago

ezhang7423 commented 1 year ago

Although decision transformer does not predict states or returns, if one were to add these losses the following prediction appears to be broken as the predict_return and predict_state projections do not take in the state, but only the action. https://github.com/kzl/decision-transformer/blob/e2d82e68f330c00f763507b3b01d774740bee53f/gym/decision_transformer/models/decision_transformer.py#L97