{
  "id": 96039,
  "title": "Features from Brute Force Feature Engineering kernel",
  "url": "/competitions/champs-scalar-coupling/discussion/96039",
  "author_name": "Andrey Lukyanenko",
  "post_date": "2019-06-17T11:16:37.422000",
  "votes": 19,
  "comment_count": 9,
  "views": 0,
  "content": "<p>I see that my features are often used by people and they generate them each time, so I have decided to calculate these features and share them in a dataset:\n<a href=\"https://www.kaggle.com/artgor/molecules-generated-features\">https://www.kaggle.com/artgor/molecules-generated-features</a>\nThe data is stored in <code>hdf5</code> files to save space and for faster loading. You can load them like this:</p>\n\n<p><code>\ntrain = pd.read_hdf(f'{path}/train.h5', 'table')\n</code>\n<code>\ntest = pd.read_hdf(f'{path}/test.h5', 'table')\n</code></p>",
  "messages": [
    {
      "id": 554396,
      "postDate": "2019-06-17T11:16:37.423Z",
      "content": "<p>I see that my features are often used by people and they generate them each time, so I have decided to calculate these features and share them in a dataset:\n<a href=\"https://www.kaggle.com/artgor/molecules-generated-features\">https://www.kaggle.com/artgor/molecules-generated-features</a>\nThe data is stored in <code>hdf5</code> files to save space and for faster loading. You can load them like this:</p>\n\n<p><code>\ntrain = pd.read_hdf(f'{path}/train.h5', 'table')\n</code>\n<code>\ntest = pd.read_hdf(f'{path}/test.h5', 'table')\n</code></p>",
      "rawMarkdown": "I see that my features are often used by people and they generate them each time, so I have decided to calculate these features and share them in a dataset:\nhttps://www.kaggle.com/artgor/molecules-generated-features\nThe data is stored in `hdf5` files to save space and for faster loading. You can load them like this:\n\n```\ntrain = pd.read_hdf(f'{path}/train.h5', 'table')\n```\n```\ntest = pd.read_hdf(f'{path}/test.h5', 'table')\n```",
      "votes": 18
    },
    {
      "id": 554858,
      "postDate": "2019-06-18T05:39:16.607Z",
      "content": "<p>when i try to load them, i get memory overflow. any tips? thanks for sharing your work btw!</p>",
      "rawMarkdown": "when i try to load them, i get memory overflow. any tips? thanks for sharing your work btw!",
      "votes": 1,
      "replies": [
        {
          "id": 554966,
          "postDate": "2019-06-18T08:45:27.523Z",
          "content": "<p>I also only managed to read in the test file. RAM usage 11.7/16 Gb after reading in only the test file.</p>",
          "rawMarkdown": "I also only managed to read in the test file. RAM usage 11.7/16 Gb after reading in only the test file."
        },
        {
          "id": 554981,
          "postDate": "2019-06-18T09:20:01.650Z",
          "content": "<p>Yes this files are too big to work with them in the kernels directly. There are some options:\n- open them on a hardware with a lot of RAM;\n- read lines belonging to one type at a time and train a model on them;\n- use subsets of columns;</p>",
          "rawMarkdown": "Yes this files are too big to work with them in the kernels directly. There are some options:\n- open them on a hardware with a lot of RAM;\n- read lines belonging to one type at a time and train a model on them;\n- use subsets of columns;",
          "votes": 2
        }
      ]
    },
    {
      "id": 554645,
      "postDate": "2019-06-17T20:13:58.390Z",
      "content": "<p>I am new to kernels but I am getting fairly good at copying others' work. Can I read the files without uploading them into my notebook?\n<code>train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features#}/train.h5', 'table')</code>\nor without #:\n<code>train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features}/train.h5', 'table')</code>\nboth give FileNotFoundError </p>\n\n<p>**Update:\nAttached files to the notebook. Still can't read them.\n<code>file_folder = '../input'\nfile_folder2 = '../input/molecules_generated_features'\ntest = pd.read_hdf(f'{file_folder}/test.h5', 'table')\ntest = pd.read_hdf(f'{file_folder2}/test.h5', 'table')</code>\nerror example: FileNotFoundError: File ../input/test.h5 does not exist. I see .h5 files in /input/molecules_generated_features/ subfolder</p>\n\n<p><em>*</em>*Update: I can't read the original test.csv either. It has something to do with the way Andrew structures his kernels I am guessing since I have not seen this problem with other people kernels.\n<code>test = pd.read_csv(f'{file_folder}/test.csv')</code>\nError: FileNotFoundError: File b'../input/test.csv' does not exist</p>",
      "rawMarkdown": "I am new to kernels but I am getting fairly good at copying others' work. Can I read the files without uploading them into my notebook?\n`train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features#}/train.h5', 'table')`\nor without #:\n`train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features}/train.h5', 'table')`\nboth give FileNotFoundError \n\n**Update:\nAttached files to the notebook. Still can't read them.\n`file_folder = '../input'\nfile_folder2 = '../input/molecules_generated_features'\ntest = pd.read_hdf(f'{file_folder}/test.h5', 'table')\ntest = pd.read_hdf(f'{file_folder2}/test.h5', 'table')`\nerror example: FileNotFoundError: File ../input/test.h5 does not exist. I see .h5 files in /input/molecules_generated_features/ subfolder\n\n****Update: I can't read the original test.csv either. It has something to do with the way Andrew structures his kernels I am guessing since I have not seen this problem with other people kernels.\n`test = pd.read_csv(f'{file_folder}/test.csv')`\nError: FileNotFoundError: File b'../input/test.csv' does not exist",
      "votes": 2,
      "replies": [
        {
          "id": 554798,
          "postDate": "2019-06-18T03:10:49.597Z",
          "content": "<p>When you have only one dataset in a kernel, its files are in <code>../input/</code> directory directly, but then you have 2 or more datasets, then in <code>../input/</code> you'll see separate folders for each dataset.</p>\n\n<p>So run <code>os.listdir(\"../input/\")</code> command and find out the way to the files.</p>",
          "rawMarkdown": "When you have only one dataset in a kernel, its files are in `../input/` directory directly, but then you have 2 or more datasets, then in `../input/` you'll see separate folders for each dataset.\n\nSo run `os.listdir(\"../input/\")` command and find out the way to the files.",
          "votes": 1
        },
        {
          "id": 554820,
          "postDate": "2019-06-18T03:50:30.280Z",
          "content": "<p>Thank you. This helped me to troubleshoot the problem. Reading the attached file OK now. The problem was that the underscores( '_' ) that I see in the workspace on the right in the browser is actually a dash ('-').\nCorrect:\n<code>os.listdir(\"../input/molecules-generated-features/\")</code></p>\n\n<p>Wrong:\n<code>os.listdir(\"../input/molecules_generated_features/\")</code></p>",
          "rawMarkdown": "Thank you. This helped me to troubleshoot the problem. Reading the attached file OK now. The problem was that the underscores( '_' ) that I see in the workspace on the right in the browser is actually a dash ('-').\nCorrect:\n`os.listdir(\"../input/molecules-generated-features/\")`\n\nWrong:\n`os.listdir(\"../input/molecules_generated_features/\")`"
        }
      ]
    },
    {
      "id": 555094,
      "postDate": "2019-06-18T12:24:32.563Z",
      "content": "<p>how can i convert .Dat file to convert  .csv  so that i will be start working </p>",
      "rawMarkdown": "how can i convert .Dat file to convert  .csv  so that i will be start working "
    },
    {
      "id": 554406,
      "postDate": "2019-06-17T11:25:04.863Z",
      "content": "<p>Sweet.</p>",
      "rawMarkdown": "Sweet."
    },
    {
      "id": 558673,
      "postDate": "2019-06-22T18:20:00.087Z",
      "rawMarkdown": "",
      "isDeleted": true
    }
  ],
  "comments": [
    {
      "id": 554858,
      "author_name": "fulowa",
      "author_url": "",
      "post_date": "2019-06-18T05:39:16.607000",
      "content": "<p>when i try to load them, i get memory overflow. any tips? thanks for sharing your work btw!</p>",
      "votes": 1,
      "replies": [
        {
          "id": 554966,
          "author_name": "Mycroft Holmes",
          "author_url": "",
          "post_date": "2019-06-18T08:45:27.523000",
          "content": "<p>I also only managed to read in the test file. RAM usage 11.7/16 Gb after reading in only the test file.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 554981,
          "author_name": "Andrey Lukyanenko",
          "author_url": "",
          "post_date": "2019-06-18T09:20:01.650000",
          "content": "<p>Yes this files are too big to work with them in the kernels directly. There are some options:\n- open them on a hardware with a lot of RAM;\n- read lines belonging to one type at a time and train a model on them;\n- use subsets of columns;</p>",
          "votes": 2,
          "replies": []
        }
      ]
    },
    {
      "id": 554645,
      "author_name": "Mycroft Holmes",
      "author_url": "",
      "post_date": "2019-06-17T20:13:58.390000",
      "content": "<p>I am new to kernels but I am getting fairly good at copying others' work. Can I read the files without uploading them into my notebook?\n<code>train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features#}/train.h5', 'table')</code>\nor without #:\n<code>train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features}/train.h5', 'table')</code>\nboth give FileNotFoundError </p>\n\n<p>**Update:\nAttached files to the notebook. Still can't read them.\n<code>file_folder = '../input'\nfile_folder2 = '../input/molecules_generated_features'\ntest = pd.read_hdf(f'{file_folder}/test.h5', 'table')\ntest = pd.read_hdf(f'{file_folder2}/test.h5', 'table')</code>\nerror example: FileNotFoundError: File ../input/test.h5 does not exist. I see .h5 files in /input/molecules_generated_features/ subfolder</p>\n\n<p><em>*</em>*Update: I can't read the original test.csv either. It has something to do with the way Andrew structures his kernels I am guessing since I have not seen this problem with other people kernels.\n<code>test = pd.read_csv(f'{file_folder}/test.csv')</code>\nError: FileNotFoundError: File b'../input/test.csv' does not exist</p>",
      "votes": 2,
      "replies": [
        {
          "id": 554798,
          "author_name": "Andrey Lukyanenko",
          "author_url": "",
          "post_date": "2019-06-18T03:10:49.597000",
          "content": "<p>When you have only one dataset in a kernel, its files are in <code>../input/</code> directory directly, but then you have 2 or more datasets, then in <code>../input/</code> you'll see separate folders for each dataset.</p>\n\n<p>So run <code>os.listdir(\"../input/\")</code> command and find out the way to the files.</p>",
          "votes": 1,
          "replies": []
        },
        {
          "id": 554820,
          "author_name": "Mycroft Holmes",
          "author_url": "",
          "post_date": "2019-06-18T03:50:30.280000",
          "content": "<p>Thank you. This helped me to troubleshoot the problem. Reading the attached file OK now. The problem was that the underscores( '_' ) that I see in the workspace on the right in the browser is actually a dash ('-').\nCorrect:\n<code>os.listdir(\"../input/molecules-generated-features/\")</code></p>\n\n<p>Wrong:\n<code>os.listdir(\"../input/molecules_generated_features/\")</code></p>",
          "votes": 0,
          "replies": []
        }
      ]
    },
    {
      "id": 555094,
      "author_name": "vicky",
      "author_url": "",
      "post_date": "2019-06-18T12:24:32.563000",
      "content": "<p>how can i convert .Dat file to convert  .csv  so that i will be start working </p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 554406,
      "author_name": "Stanislav Blinov",
      "author_url": "",
      "post_date": "2019-06-17T11:25:04.863000",
      "content": "<p>Sweet.</p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 558673,
      "author_name": "",
      "author_url": "",
      "post_date": "2019-06-22T18:20:00.087000",
      "content": "",
      "votes": 0,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "554396": "I see that my features are often used by people and they generate them each time, so I have decided to calculate these features and share them in a dataset:\nhttps://www.kaggle.com/artgor/molecules-generated-features\nThe data is stored in `hdf5` files to save space and for faster loading. You can load them like this:\n\n```\ntrain = pd.read_hdf(f'{path}/train.h5', 'table')\n```\n```\ntest = pd.read_hdf(f'{path}/test.h5', 'table')\n```",
    "554858": "when i try to load them, i get memory overflow. any tips? thanks for sharing your work btw!",
    "554645": "I am new to kernels but I am getting fairly good at copying others' work. Can I read the files without uploading them into my notebook?\n`train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features#}/train.h5', 'table')`\nor without #:\n`train = pd.read_hdf(f'{https://www.kaggle.com/artgor/molecules_generated_features}/train.h5', 'table')`\nboth give FileNotFoundError \n\n**Update:\nAttached files to the notebook. Still can't read them.\n`file_folder = '../input'\nfile_folder2 = '../input/molecules_generated_features'\ntest = pd.read_hdf(f'{file_folder}/test.h5', 'table')\ntest = pd.read_hdf(f'{file_folder2}/test.h5', 'table')`\nerror example: FileNotFoundError: File ../input/test.h5 does not exist. I see .h5 files in /input/molecules_generated_features/ subfolder\n\n****Update: I can't read the original test.csv either. It has something to do with the way Andrew structures his kernels I am guessing since I have not seen this problem with other people kernels.\n`test = pd.read_csv(f'{file_folder}/test.csv')`\nError: FileNotFoundError: File b'../input/test.csv' does not exist",
    "555094": "how can i convert .Dat file to convert  .csv  so that i will be start working ",
    "554406": "Sweet.",
    "558673": ""
  }
}