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

Better logging for materialize command #1499

Merged
merged 4 commits into from
May 11, 2021

Conversation

jklegar
Copy link
Collaborator

@jklegar jklegar commented Apr 23, 2021

Signed-off-by: Jacob Klegar jacob@tecton.ai

What this PR does / why we need it: Improve logging for materialize and materialize_incremental

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?:

NONE

lambda b: _write_minibatch(client, project, table, b, progress),
_to_minibatches(data),
)
with tqdm(total=len(data)) as pbar:
Copy link
Member

@woop woop Apr 23, 2021

Choose a reason for hiding this comment

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

I think it may be better to have tqdm at a higher level so that its not optional to do progress bar logging. Would it make more sense in materialize_incremental() and then pass it into materialize_single_feature_view?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I don't see an easy way to bring it up to materialize_incremental since we don't know the number of rows of data at that level; however, progress is an argument in methods in the Provider class so that kinda makes it not optional for implementations of Provider to do some sort of progress logging, presumably by copying existing implementations and using tqdm

Copy link
Member

Choose a reason for hiding this comment

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

I thought I replied here, but somehow my message didn't send. I think my question is just: How can we ensure consistency in the logging output if the implementations need to create their own tqdm object. Wouldn't the current implementation make it unscalable to have different configurations for tqdm? Even if the row count is deeper, maybe it makes sense to instantiate the tqdm object higher and pass it into the implementation.

@woop
Copy link
Member

woop commented Apr 23, 2021

image

Nitpicks:

  • do we need microseconds in the logs?
  • I prefer "to" to "until" and "from" instead of "starting at"
  • I also think that its weird that we talk about the end date before the start date, instead of start->end together.
  • I also think we can have fixed width bars instead of using the full console width.

edit: For none of these points I feel super strongly though. Happy to keep as is.

@jklegar
Copy link
Collaborator Author

jklegar commented Apr 27, 2021

/kind housekeeping

Signed-off-by: Jacob Klegar <jacob@tecton.ai>
Signed-off-by: Jacob Klegar <jacob@tecton.ai>
Signed-off-by: Jacob Klegar <jacob@tecton.ai>
Signed-off-by: Jacob Klegar <jacob@tecton.ai>
@jklegar jklegar force-pushed the jacob_materialize_logging branch from aa2757c to 0ebf141 Compare May 4, 2021 16:45
@tsotnet
Copy link
Collaborator

tsotnet commented May 11, 2021

/lgtm

@feast-ci-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jklegar, tsotnet

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@feast-ci-bot feast-ci-bot merged commit d46e4bd into feast-dev:master May 11, 2021
jklegar added a commit to jklegar/feast that referenced this pull request May 12, 2021
* Better logging for materialize command

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Address comments

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Move tqdm to FeatureStore class

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Rebase

Signed-off-by: Jacob Klegar <jacob@tecton.ai>
jklegar added a commit that referenced this pull request May 12, 2021
* Better logging for materialize command

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Address comments

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Move tqdm to FeatureStore class

Signed-off-by: Jacob Klegar <jacob@tecton.ai>

* Rebase

Signed-off-by: Jacob Klegar <jacob@tecton.ai>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants