【问题标题】:Is my cpu usage normal while using selenium?使用 selenium 时我的 cpu 使用率是否正常?
【发布时间】:2022-01-01 19:49:45
【问题描述】:

运行这个 selenium 脚本时,我的 CPU 使用率平均为 17%,峰值为 22%。这是正常的吗?我有一个 5 5600g 处理器并且没有在后台运行任何东西。提前致谢。

Button = driver.find_elements(By.CLASS_NAME, "button")
while not (driver.find_elements(By.CLASS_NAME, "button")):
    time.sleep(1)
    driver.refresh()
Button[0].click() 

【问题讨论】:

    标签: python selenium cpu-usage


    【解决方案1】:

    在使用Selenium 执行测试时,官方没有关于CPU 使用情况的基准测试。

    因此,我不会对 CPU 使用率平均为 17%(峰值为 22%)感到惊讶strong> 即使是 5 5600g 处理器,历史上也是如此:

    并且修复步骤在:

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-08-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-03-06
      • 1970-01-01
      相关资源
      最近更新 更多