{
  "id": 441445,
  "title": "Understanding the Layout Configuration",
  "url": "/competitions/predict-ai-model-runtime/discussion/441445",
  "author_name": "",
  "post_date": "2023-09-18T19:32:18.463873800Z",
  "votes": 4,
  "comment_count": 4,
  "views": 0,
  "content": "<p>Hi, I got stuck to know specifically the following image in relation to the operations and input/output, for example, what does it mean add [2,4,16] and {1,0,2}. Another question is how to know the node order, what is the config[i] for i in general and how node_config_ids are organized?</p>\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F6693355%2F6cf599b7ba71b201af412cf272b907ec%2Fconfig%20TPU%20layout.png?generation=1695065516115851&amp;alt=media\" alt=\"\"></p>",
  "messages": [
    {
      "id": "2445391",
      "postDate": "09/18/2023 19:32:18",
      "content": "<p>Hi, I got stuck to know specifically the following image in relation to the operations and input/output, for example, what does it mean add [2,4,16] and {1,0,2}. Another question is how to know the node order, what is the config[i] for i in general and how node_config_ids are organized?</p>\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F6693355%2F6cf599b7ba71b201af412cf272b907ec%2Fconfig%20TPU%20layout.png?generation=1695065516115851&amp;alt=media\" alt=\"\"></p>",
      "rawMarkdown": "Hi, I got stuck to know specifically the following image in relation to the operations and input/output, for example, what does it mean add [2,4,16] and {1,0,2}. Another question is how to know the node order, what is the config[i] for i in general and how node_config_ids are organized?\n\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F6693355%2F6cf599b7ba71b201af412cf272b907ec%2Fconfig%20TPU%20layout.png?generation=1695065516115851&alt=media)",
      "votes": null
    },
    {
      "id": "2445503",
      "postDate": "09/18/2023 22:05:43",
      "content": "<p>Hey,<br>\nI am not an expert on this field, so please correct me if I am wrong.<br>\nIn the image above \"add [2,4,16] and {1,0,2}\" means, that the node \"add\" has an output of shape [2,4,16] and its layout is in minor-to-major order. Look at the discussion \"What is a Tensor Processing Unit (TPU)?\" for more details about the layout.<br>\nThe order of the graph is saved in the variable \"edge_index\". The variable \"node_config_ids\" specifies the configurable nodes in the graph, i.e., in this case the nodes \"reshape\" and \"conv\" are configurable.</p>",
      "rawMarkdown": "Hey,\nI am not an expert on this field, so please correct me if I am wrong.\nIn the image above \"add [2,4,16] and {1,0,2}\" means, that the node \"add\" has an output of shape [2,4,16] and its layout is in minor-to-major order. Look at the discussion \"What is a Tensor Processing Unit (TPU)?\" for more details about the layout.\nThe order of the graph is saved in the variable \"edge_index\". The variable \"node_config_ids\" specifies the configurable nodes in the graph, i.e., in this case the nodes \"reshape\" and \"conv\" are configurable.",
      "votes": null
    },
    {
      "id": "2447394",
      "postDate": "09/20/2023 03:54:47",
      "content": "<p>All are correct! Except that \"edge_index\" is a list of edges, not the order of the graph.</p>",
      "rawMarkdown": "All are correct! Except that \"edge_index\" is a list of edges, not the order of the graph.",
      "votes": null
    },
    {
      "id": "2448020",
      "postDate": "09/20/2023 11:30:25",
      "content": "<p>What is exactly the \"minor-to-major order\" concept?</p>",
      "rawMarkdown": "What is exactly the \"minor-to-major order\" concept?",
      "votes": null
    },
    {
      "id": "2449947",
      "postDate": "09/21/2023 14:35:48",
      "content": "<p>Thank you for clarifying that 'edge_index' doesn't pertain to the graph's order. It's good to have that distinction clear.</p>\n<p>Now, as for 'minor-to-major order,' it's an essential concept in tensor layouts. In essence, it dictates the sequence in which dimensions are organized within a tensor shape. The notation '{1, 0, 2}' specifies the order in which these dimensions are arranged, with 1 as the least significant dimension, followed by 0, and then 2, which is considered the most significant.</p>\n<p>Please do correct me if I'm mistaken, as I'm not an expert in this field as well, but understanding this order is vital. It directly influences how data is stored in memory and how operations are applied to the tensor. Different deep learning frameworks and hardware architectures may have their own conventions for tensor layouts, so having this awareness can be incredibly helpful when designing and optimizing models for specific platforms.</p>",
      "rawMarkdown": "Thank you for clarifying that 'edge_index' doesn't pertain to the graph's order. It's good to have that distinction clear.\n\nNow, as for 'minor-to-major order,' it's an essential concept in tensor layouts. In essence, it dictates the sequence in which dimensions are organized within a tensor shape. The notation '{1, 0, 2}' specifies the order in which these dimensions are arranged, with 1 as the least significant dimension, followed by 0, and then 2, which is considered the most significant.\n\nPlease do correct me if I'm mistaken, as I'm not an expert in this field as well, but understanding this order is vital. It directly influences how data is stored in memory and how operations are applied to the tensor. Different deep learning frameworks and hardware architectures may have their own conventions for tensor layouts, so having this awareness can be incredibly helpful when designing and optimizing models for specific platforms.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 2445503,
      "author_name": "tobiasschubert",
      "author_url": "",
      "post_date": "09/18/2023 22:05:43",
      "content": "<p>Hey,<br>\nI am not an expert on this field, so please correct me if I am wrong.<br>\nIn the image above \"add [2,4,16] and {1,0,2}\" means, that the node \"add\" has an output of shape [2,4,16] and its layout is in minor-to-major order. Look at the discussion \"What is a Tensor Processing Unit (TPU)?\" for more details about the layout.<br>\nThe order of the graph is saved in the variable \"edge_index\". The variable \"node_config_ids\" specifies the configurable nodes in the graph, i.e., in this case the nodes \"reshape\" and \"conv\" are configurable.</p>",
      "votes": null,
      "replies": [
        {
          "id": 2447394,
          "author_name": "mangpophothilimthana",
          "author_url": "",
          "post_date": "09/20/2023 03:54:47",
          "content": "<p>All are correct! Except that \"edge_index\" is a list of edges, not the order of the graph.</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 2448020,
          "author_name": "joaovictormelo",
          "author_url": "",
          "post_date": "09/20/2023 11:30:25",
          "content": "<p>What is exactly the \"minor-to-major order\" concept?</p>",
          "votes": null,
          "replies": [
            {
              "id": 2449947,
              "author_name": "rukaiyabinteshafique",
              "author_url": "",
              "post_date": "09/21/2023 14:35:48",
              "content": "<p>Thank you for clarifying that 'edge_index' doesn't pertain to the graph's order. It's good to have that distinction clear.</p>\n<p>Now, as for 'minor-to-major order,' it's an essential concept in tensor layouts. In essence, it dictates the sequence in which dimensions are organized within a tensor shape. The notation '{1, 0, 2}' specifies the order in which these dimensions are arranged, with 1 as the least significant dimension, followed by 0, and then 2, which is considered the most significant.</p>\n<p>Please do correct me if I'm mistaken, as I'm not an expert in this field as well, but understanding this order is vital. It directly influences how data is stored in memory and how operations are applied to the tensor. Different deep learning frameworks and hardware architectures may have their own conventions for tensor layouts, so having this awareness can be incredibly helpful when designing and optimizing models for specific platforms.</p>",
              "votes": null,
              "replies": []
            }
          ]
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "2445391": "Hi, I got stuck to know specifically the following image in relation to the operations and input/output, for example, what does it mean add [2,4,16] and {1,0,2}. Another question is how to know the node order, what is the config[i] for i in general and how node_config_ids are organized?\n\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F6693355%2F6cf599b7ba71b201af412cf272b907ec%2Fconfig%20TPU%20layout.png?generation=1695065516115851&alt=media)",
    "2445503": "Hey,\nI am not an expert on this field, so please correct me if I am wrong.\nIn the image above \"add [2,4,16] and {1,0,2}\" means, that the node \"add\" has an output of shape [2,4,16] and its layout is in minor-to-major order. Look at the discussion \"What is a Tensor Processing Unit (TPU)?\" for more details about the layout.\nThe order of the graph is saved in the variable \"edge_index\". The variable \"node_config_ids\" specifies the configurable nodes in the graph, i.e., in this case the nodes \"reshape\" and \"conv\" are configurable.",
    "2447394": "All are correct! Except that \"edge_index\" is a list of edges, not the order of the graph.",
    "2448020": "What is exactly the \"minor-to-major order\" concept?",
    "2449947": "Thank you for clarifying that 'edge_index' doesn't pertain to the graph's order. It's good to have that distinction clear.\n\nNow, as for 'minor-to-major order,' it's an essential concept in tensor layouts. In essence, it dictates the sequence in which dimensions are organized within a tensor shape. The notation '{1, 0, 2}' specifies the order in which these dimensions are arranged, with 1 as the least significant dimension, followed by 0, and then 2, which is considered the most significant.\n\nPlease do correct me if I'm mistaken, as I'm not an expert in this field as well, but understanding this order is vital. It directly influences how data is stored in memory and how operations are applied to the tensor. Different deep learning frameworks and hardware architectures may have their own conventions for tensor layouts, so having this awareness can be incredibly helpful when designing and optimizing models for specific platforms."
  },
  "source": "meta"
}