Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Inverse of VecNorm Transform #2347

Open
1 task done
btx0424 opened this issue Aug 1, 2024 · 1 comment
Open
1 task done

[Feature Request] Inverse of VecNorm Transform #2347

btx0424 opened this issue Aug 1, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@btx0424
Copy link
Contributor

btx0424 commented Aug 1, 2024

Motivation

There are a range of cases where we would like to recover the original data.

Solution

Adding a method to VecNorm to denormalize a tensordict or return a separate class for this purpose.

For example:

env = TransformedEnv(env, VecNorm(...))
tensordict = env.rollout(...)

tensordict_denormed = vecnorm.denorm(tensordict)
# or
denorm = VecNorm.get_denorm()
tensordict_denormed = denorm(tensordict)

Additional context

Glad to implement it in whichever solution you feel comfortable with.

Checklist

  • I have checked that there is no similar issue in the repo (required)
@btx0424 btx0424 added the enhancement New feature or request label Aug 1, 2024
@vmoens
Copy link
Contributor

vmoens commented Aug 2, 2024

Sounds reasonable, there's a whole stack of things I want to do to improve vecnorm, i'll add that to the list!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants