pandas.read_html() is taking too long to return the list of tables lately, if the html size is > 5 mb
pandas.read_html() is taking too long to return the list of tables lately, if the html size is > 5 mb. if there are only a couple of tables pd.read_html() return the list instantly but if has 10 tables then its taking forever. this was never a problem before. i built my entire project based on this. and now everything's a bust because somewhere something blew up internally and no one seems to be bothered. I cannot give any data( confidential else i wouldn't have a problem and am unable to find any websites hat have multiple tables(>5) in a single page. There are either one or two tables or images of the tables.) to duplicate the code but can explain how to recreate it.
import pandas as pd
file=r'_path_to_html_file' # this file should be a large (>5 mb with mutliple tables >5)
#else the problem wont be triggered
tables=pd.read_html(file)
# this will return a list within a second usually a couple of months ago when i finished my project.
#but of late it takes forever(>30-40 minutes for a 16 mb html file) to do so.
python html pandas
|
show 1 more comment
pandas.read_html() is taking too long to return the list of tables lately, if the html size is > 5 mb. if there are only a couple of tables pd.read_html() return the list instantly but if has 10 tables then its taking forever. this was never a problem before. i built my entire project based on this. and now everything's a bust because somewhere something blew up internally and no one seems to be bothered. I cannot give any data( confidential else i wouldn't have a problem and am unable to find any websites hat have multiple tables(>5) in a single page. There are either one or two tables or images of the tables.) to duplicate the code but can explain how to recreate it.
import pandas as pd
file=r'_path_to_html_file' # this file should be a large (>5 mb with mutliple tables >5)
#else the problem wont be triggered
tables=pd.read_html(file)
# this will return a list within a second usually a couple of months ago when i finished my project.
#but of late it takes forever(>30-40 minutes for a 16 mb html file) to do so.
python html pandas
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
I have html file of 5 MB with[13895 rows x 13 columns]it takes only minute to process?
– pygo
Nov 26 '18 at 4:01
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59
|
show 1 more comment
pandas.read_html() is taking too long to return the list of tables lately, if the html size is > 5 mb. if there are only a couple of tables pd.read_html() return the list instantly but if has 10 tables then its taking forever. this was never a problem before. i built my entire project based on this. and now everything's a bust because somewhere something blew up internally and no one seems to be bothered. I cannot give any data( confidential else i wouldn't have a problem and am unable to find any websites hat have multiple tables(>5) in a single page. There are either one or two tables or images of the tables.) to duplicate the code but can explain how to recreate it.
import pandas as pd
file=r'_path_to_html_file' # this file should be a large (>5 mb with mutliple tables >5)
#else the problem wont be triggered
tables=pd.read_html(file)
# this will return a list within a second usually a couple of months ago when i finished my project.
#but of late it takes forever(>30-40 minutes for a 16 mb html file) to do so.
python html pandas
pandas.read_html() is taking too long to return the list of tables lately, if the html size is > 5 mb. if there are only a couple of tables pd.read_html() return the list instantly but if has 10 tables then its taking forever. this was never a problem before. i built my entire project based on this. and now everything's a bust because somewhere something blew up internally and no one seems to be bothered. I cannot give any data( confidential else i wouldn't have a problem and am unable to find any websites hat have multiple tables(>5) in a single page. There are either one or two tables or images of the tables.) to duplicate the code but can explain how to recreate it.
import pandas as pd
file=r'_path_to_html_file' # this file should be a large (>5 mb with mutliple tables >5)
#else the problem wont be triggered
tables=pd.read_html(file)
# this will return a list within a second usually a couple of months ago when i finished my project.
#but of late it takes forever(>30-40 minutes for a 16 mb html file) to do so.
python html pandas
python html pandas
asked Nov 26 '18 at 2:58
venkat.gmrit05venkat.gmrit05
11
11
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
I have html file of 5 MB with[13895 rows x 13 columns]it takes only minute to process?
– pygo
Nov 26 '18 at 4:01
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59
|
show 1 more comment
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
I have html file of 5 MB with[13895 rows x 13 columns]it takes only minute to process?
– pygo
Nov 26 '18 at 4:01
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
I have html file of 5 MB with
[13895 rows x 13 columns] it takes only minute to process?– pygo
Nov 26 '18 at 4:01
I have html file of 5 MB with
[13895 rows x 13 columns] it takes only minute to process?– pygo
Nov 26 '18 at 4:01
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59
|
show 1 more comment
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53474241%2fpandas-read-html-is-taking-too-long-to-return-the-list-of-tables-lately-if-th%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53474241%2fpandas-read-html-is-taking-too-long-to-return-the-list-of-tables-lately-if-th%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Use selenium to web scraping that is much faster..
– min2bro
Nov 26 '18 at 3:39
What is the size of Memory on the system you running this operation?
– pygo
Nov 26 '18 at 3:54
I have html file of 5 MB with
[13895 rows x 13 columns]it takes only minute to process?– pygo
Nov 26 '18 at 4:01
@min2bro will try. although i found another way around the problem. Thank you.
– venkat.gmrit05
Nov 26 '18 at 7:58
@pygo its runnig on an 8 gb machine. even when it was runnign fast it was the same system.
– venkat.gmrit05
Nov 26 '18 at 7:59