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

[ENH] Representation functions calculation in fit are necessary in QUANTTranformer? #2722

Open
MatthewMiddlehurst opened this issue Apr 3, 2025 · 1 comment · May be fixed by #2727
Open
Labels
enhancement New feature, improvement request or other non-bug code enhancement transformations Transformations package

Comments

@MatthewMiddlehurst
Copy link
Member

Discussed in #2719

Originally posted by danielnowakassis April 2, 2025
In QUANTTranformer

These representation functions are calculated for training data :

representation_functions = (
          lambda X: X,
          lambda X: F.avg_pool1d(F.pad(X.diff(), (2, 2), "replicate"), 5, 1),
          lambda X: X.diff(n=2),
          lambda X: torch.fft.rfft(X).abs(),
)

And only the shape of the results are extracted :

for function in representation_functions:
            Z = function(X)
            self.intervals_.append(self._make_intervals(input_length=Z.shape[-1]))

Can the shape of the representation functions be specified instead of unnecessary calculations for training data?

@MatthewMiddlehurst MatthewMiddlehurst added enhancement New feature, improvement request or other non-bug code enhancement transformations Transformations package labels Apr 3, 2025
@shinymack
Copy link
Contributor

I am working on this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature, improvement request or other non-bug code enhancement transformations Transformations package
Projects
None yet
2 participants