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

Log warning polluting my console with "New timestamp is equal or less than the last one" #5726

Open
RossLote opened this issue Nov 12, 2024 · 0 comments
Assignees
Labels
os:macOS Issues on MacOS platform:python MediaPipe Python issues stat:awaiting googler Waiting for Google Engineer's Response task:pose landmarker Issues related to Pose Landmarker: Find people and body positions type:bug Bug in the Source Code of MediaPipe Solution

Comments

@RossLote
Copy link

RossLote commented Nov 12, 2024

Have I written custom code (as opposed to using a stock example script provided in MediaPipe)

No

OS Platform and Distribution

MacOS 15.0.1

Mobile device if the issue happens on mobile device

No response

Browser and version if the issue happens on browser

No response

Programming Language and version

Python

MediaPipe version

0.10.18

Bazel version

No response

Solution

Pose

Android Studio, NDK, SDK versions (if issue is related to building in Android environment)

No response

Xcode & Tulsi version (if issue is related to building for iOS)

No response

Describe the actual behavior

Outputs too many warning

Describe the expected behaviour

Don't do that

Standalone code/steps you may have used to try to get what you need

model_path = get_model_path("pose_landmarker_heavy.task")

BaseOptions = mp.tasks.BaseOptions
PoseLandmarker = mp.tasks.vision.PoseLandmarker
PoseLandmarkerOptions = mp.tasks.vision.PoseLandmarkerOptions
VisionRunningMode = mp.tasks.vision.RunningMode

options = PoseLandmarkerOptions(
    base_options=BaseOptions(model_asset_path=model_path),
    running_mode=VisionRunningMode.LIVE_STREAM,
    result_callback=result_callback,
)
landmarker = PoseLandmarker.create_from_options(options)

while True:
  // get frame
  mp_image = mp.Image(image_format=mp.ImageFormat.SRGB, data=frame.image)
  timestamp = mp.Timestamp.from_seconds(
    frame.frame_timestamp.timestamp()
  ).microseconds()
  logger.debug(f"Predicting pose at timestamp: {timestamp}")
  landmarker.detect_async(mp_image, timestamp)

If you check the logs you will see that my timestamps are incrementing.
These logs are really annoying as they make printing to the console pointless as there are 1000's every second.



### Other info / Complete Logs

```shell
My debug log shows:

2024-11-12 23:39:35,100:DEBUG:Predicting pose at timestamp: 1731454775050570
2024-11-12 23:39:35,157:DEBUG:Predicting pose at timestamp: 1731454775057239
2024-11-12 23:39:35,218:DEBUG:Predicting pose at timestamp: 1731454775060507
2024-11-12 23:39:35,268:DEBUG:Predicting pose at timestamp: 1731454775183180
2024-11-12 23:39:35,394:DEBUG:Predicting pose at timestamp: 1731454775186423
2024-11-12 23:39:35,446:DEBUG:Predicting pose at timestamp: 1731454775359237
2024-11-12 23:39:35,638:DEBUG:Predicting pose at timestamp: 1731454775591741
2024-11-12 23:39:35,692:DEBUG:Predicting pose at timestamp: 1731454775599519
2024-11-12 23:39:35,864:DEBUG:Predicting pose at timestamp: 1731454775812444
2024-11-12 23:39:35,919:DEBUG:Predicting pose at timestamp: 1731454775819363
2024-11-12 23:39:36,104:DEBUG:Predicting pose at timestamp: 1731454776050883
2024-11-12 23:39:36,159:DEBUG:Predicting pose at timestamp: 1731454776059214

The warnings in the terminal show:

W0000 00:00:1731454775.946410 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946414 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946418 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946423 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946429 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946433 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946437 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946441 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946446 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946451 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454775.946455 62858690 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022882 62858682 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022939 62858682 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022947 62858682 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022952 62858682 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022895 62858691 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022970 62858691 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
W0000 00:00:1731454776.022978 62858691 one_euro_filter.cc:32] New timestamp is equal or less than the last one.
@RossLote RossLote added the type:bug Bug in the Source Code of MediaPipe Solution label Nov 12, 2024
@kuaashish kuaashish added os:macOS Issues on MacOS python Pull requests that update Python code task:pose landmarker Issues related to Pose Landmarker: Find people and body positions labels Nov 13, 2024
@kuaashish kuaashish added stat:awaiting googler Waiting for Google Engineer's Response platform:python MediaPipe Python issues and removed python Pull requests that update Python code labels Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
os:macOS Issues on MacOS platform:python MediaPipe Python issues stat:awaiting googler Waiting for Google Engineer's Response task:pose landmarker Issues related to Pose Landmarker: Find people and body positions type:bug Bug in the Source Code of MediaPipe Solution
Projects
None yet
Development

No branches or pull requests

3 participants