{
  "id": 377912,
  "title": "Preprocessing: Is there any faster way to do this below?",
  "url": "/competitions/nfl-player-contact-detection/discussion/377912",
  "author_name": "",
  "post_date": "2023-01-13T11:55:41.493102600Z",
  "votes": 1,
  "comment_count": 1,
  "views": 0,
  "content": "<p><code>df1 = hl[(hl.game_play == gp) &amp; (hl.nfl_player_id == p1) &amp; (hl.frame=f)]</code><br>\n<em>Pandas is very much slow</em></p>",
  "messages": [
    {
      "id": "2098288",
      "postDate": "01/13/2023 11:55:41",
      "content": "<p><code>df1 = hl[(hl.game_play == gp) &amp; (hl.nfl_player_id == p1) &amp; (hl.frame=f)]</code><br>\n<em>Pandas is very much slow</em></p>",
      "rawMarkdown": "`df1 = hl[(hl.game_play == gp) & (hl.nfl_player_id == p1) & (hl.frame=f)]`\n*Pandas is very much slow*",
      "votes": null
    },
    {
      "id": "2100068",
      "postDate": "01/14/2023 22:55:34",
      "content": "<p>You should first get a sub dataframe with the hl.game_play == gp and then filter the player_ids and frames over that copy. That way you are not looking the whole dataframe again to look for the rows with the same gameplay.</p>",
      "rawMarkdown": "You should first get a sub dataframe with the hl.game_play == gp and then filter the player_ids and frames over that copy. That way you are not looking the whole dataframe again to look for the rows with the same gameplay.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 2100068,
      "author_name": "ricardfos",
      "author_url": "",
      "post_date": "01/14/2023 22:55:34",
      "content": "<p>You should first get a sub dataframe with the hl.game_play == gp and then filter the player_ids and frames over that copy. That way you are not looking the whole dataframe again to look for the rows with the same gameplay.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "2098288": "`df1 = hl[(hl.game_play == gp) & (hl.nfl_player_id == p1) & (hl.frame=f)]`\n*Pandas is very much slow*",
    "2100068": "You should first get a sub dataframe with the hl.game_play == gp and then filter the player_ids and frames over that copy. That way you are not looking the whole dataframe again to look for the rows with the same gameplay."
  },
  "source": "meta"
}