Deepakchawla / Mobile-Phone-Dataset-GSMArena

Python script for creating Mobile Phones Dataset on GSMArena website.
MIT License
59 stars 46 forks source link

Not completely native Python code since it uses pwd, thus not working on Windows #7

Closed opus-x closed 3 years ago

opus-x commented 4 years ago

Please change the following line: line 20: self.absolute_path = os.popen('pwd').read().strip() + '/' + self.new_folder_name # It create the absolute path of the GSMArenaDataset folder.

new code: self.absolute_path = os.path.dirname(os.path.realpath(__file__)) + '/' + self.new_folder_name # It create the absolute path of the GSMArenaDataset folder.

krm1337 commented 3 years ago

This also works: self.absolute_path = os.getcwd() + '/' + self.new_folder_name +'/' # It create the absolute path of the GSMArenaDataset folder.

Sahil-Ajmera commented 3 years ago

I have added a PR to update the code https://github.com/Deepakchawla/Mobile-Phone-Dataset-GSMArena/pull/10 Hopefully that fixes things.

Deepakchawla commented 3 years ago

code has been updated now guys will not get the issue.