Coder Social home page Coder Social logo

Comments (7)

asinofsky avatar asinofsky commented on June 3, 2024 1

If I delete the data and rerun it, it seems to work, so I think it's only when there was existing fighter data etc. it was trying to use.

from ufc-predictions.

asinofsky avatar asinofsky commented on June 3, 2024

from ufc-predictions.

ojneto avatar ojneto commented on June 3, 2024

Yes, I'm using windows. I managed to run the command. However, the following error appears:

Creating fight data

Scraping links!
Scraping event and fight links:
Progress: |██████████████████████████████████████████████████| 100.00% Complete
Successfully scraped and saved event and fight links!

Now, scraping event and fight data!

Scraping data for 595 fights:
Progress: |--------------------------------------------------| 0.00% Complete

TypeError Traceback (most recent call last)
in
2 print("Creating fight data \n")
3 fight_data_scraper = FightDataScraper()
----> 4 fight_data_scraper.create_fight_data_csv() # Scrapes raw ufc fight data from website
5 print(f'elapsed seconds = {(time.time() - time_start):.2f}')

~\Documents\UFC-Predictions-master\UFC-Predictions-master\src\createdata\scrape_fight_data.py in create_fight_data_csv(self)
43 self._scrape_raw_fight_data(
44 all_events_and_fight_links,
---> 45 filepath=self.TOTAL_EVENT_AND_FIGHTS_PATH,
46 )
47 else:

~\Documents\UFC-Predictions-master\UFC-Predictions-master\src\createdata\scrape_fight_data.py in _scrape_raw_fight_data(self, event_and_fight_links, filepath)
77 print(f'File {filepath} already exists, overwriting.')
78
---> 79 total_stats = FightDataScraper._get_total_fight_stats(event_and_fight_links)
80 with open(filepath.as_posix(), "wb") as file:
81 file.write(bytes(self.HEADER, encoding="ascii", errors="ignore"))

~\Documents\UFC-Predictions-master\UFC-Predictions-master\src\createdata\scrape_fight_data.py in _get_total_fight_stats(cls, event_and_fight_links)
121 futures = []
122 for fight in fights:
--> 123 futures.append(executor.submit(FightDataScraper._get_fight_stats_task, self=cls, fight=fight, event_info=event_info))
124 for future in concurrent.futures.as_completed(futures):
125 fighter_stats = future.result()

TypeError: submit() got multiple values for argument 'self'

from ufc-predictions.

asinofsky avatar asinofsky commented on June 3, 2024

from ufc-predictions.

ojneto avatar ojneto commented on June 3, 2024

I thank your attention. Could you briefly describe how you managed to get the updated data?

from ufc-predictions.

asinofsky avatar asinofsky commented on June 3, 2024

from ufc-predictions.

ojneto avatar ojneto commented on June 3, 2024

I keep trying.
Thank you for your help.

from ufc-predictions.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.