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

Support SELECT expr; which does not require FROM table #1087

Merged
merged 16 commits into from
Sep 12, 2023

Conversation

xzdandy
Copy link
Collaborator

@xzdandy xzdandy commented Sep 10, 2023

Address the SELECT Forecast(12) FROM AirData; to SELECT Forecast(12); in #1081

  • update parser, binder, optimizer, and executor to allow project without children.
  • update forecasting test cases and documentation.
  • add unit test and short integration test for SELECT expr;.
  • add documentation that we support SELECT expr;.

@xzdandy xzdandy self-assigned this Sep 10, 2023
@xzdandy xzdandy added the Feature Request ✨ New feature or request label Sep 10, 2023
@xzdandy xzdandy added this to the v0.3.5 milestone Sep 10, 2023
@xzdandy xzdandy marked this pull request as ready for review September 11, 2023 08:22
@xzdandy
Copy link
Collaborator Author

xzdandy commented Sep 11, 2023

Discussed offline. We will send a dummy batch instead of checking batch is None everywhere.

@xzdandy
Copy link
Collaborator Author

xzdandy commented Sep 12, 2023

@gaurav274 @jiashenC Please review. We should be ready for a forecasting notebook after this PR.

Copy link
Member

@jiashenC jiashenC left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, the PR looks good to me.

Just curious about the workflow of the forecasting model for my own knowledge.

  • During training (i.e., CREATE FUNCTION), the forecasting model reads a table and memorizes all of the data from the table to its internal state (e.g., weights).
  • During inference, the forecasting model outputs the prediction from its internal state.

Is this the reason why the SeqScan is no longer needed during inference?

@xzdandy
Copy link
Collaborator Author

xzdandy commented Sep 12, 2023

Thanks, the PR looks good to me.

Just curious about the workflow of the forecasting model for my own knowledge.

  • During training (i.e., CREATE FUNCTION), the forecasting model reads a table and memorizes all of the data from the table to its internal state (e.g., weights).
  • During inference, the forecasting model outputs the prediction from its internal state.

Is this the reason why the SeqScan is no longer needed during inference?

Yes. It always works on the original dataset or table.

@xzdandy xzdandy merged commit 0731b1b into staging Sep 12, 2023
5 checks passed
@xzdandy xzdandy deleted the select_without_from branch September 12, 2023 15:05
@jiashenC
Copy link
Member

Thanks, the PR looks good to me.
Just curious about the workflow of the forecasting model for my own knowledge.

  • During training (i.e., CREATE FUNCTION), the forecasting model reads a table and memorizes all of the data from the table to its internal state (e.g., weights).
  • During inference, the forecasting model outputs the prediction from its internal state.

Is this the reason why the SeqScan is no longer needed during inference?

Yes. It always works on the original dataset or table.

I see. Then, if the user wants the same model to work with a different dataset, the user needs to call CREATE FUNCTION again. Is that correct?

@xzdandy
Copy link
Collaborator Author

xzdandy commented Sep 12, 2023

Thanks, the PR looks good to me.
Just curious about the workflow of the forecasting model for my own knowledge.

  • During training (i.e., CREATE FUNCTION), the forecasting model reads a table and memorizes all of the data from the table to its internal state (e.g., weights).
  • During inference, the forecasting model outputs the prediction from its internal state.

Is this the reason why the SeqScan is no longer needed during inference?

Yes. It always works on the original dataset or table.

I see. Then, if the user wants the same model to work with a different dataset, the user needs to call CREATE FUNCTION again. Is that correct?

That is correct. On the other hand, If I understand correctly, for forecasting, the same model can not work for other datesets. It is trained for a specific dataset. @americast who should have more knowledge in this space.

@americast
Copy link
Member

Thanks @xzdandy for the PR aned @jiashenC for the review. Right, a function would be linked to a trained model linked to a specific dataset. Thus, while calling the function, we would not need to pass any dataset information.

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

Successfully merging this pull request may close these issues.

None yet

3 participants