Question
Book Reviews Description You are to build a book review OOP system using the data in the given dataset described below and provide an initial
Users Contains the users. Note that user IDs (User-ID) have been anonymized and map to unique serially incremented integers. Demographic data is provided (Location, Ape) if available. Otherwise, these fields contain Nuu-values, empty Reviews Contains the book rating information. Ratings (Book-Rating) are either explicit, expressed on a scale from 2-10 (higher values denoting higher appreciation), or implicit, expressed by O.
A user might have reviewed multiple books and a book might have been reviewed by multiple users. Full processing of this file is required for each book and each user that takes very long time. Therefore, you will use the file Reviesas_smaltes instead. Tasks 1. Code the following classes in the file bookdataset.py Book Attributes instance attributes representing isbn, book_title, book_author, year_of_publication, publishet, rating and rating_count Methods 3 it also initializes rating and rating_count to Location Attributes instance attributes representing: city, state, and country Methods init User Attributez instance attributes representing user_id, password, location, age, and the list reviewed Methods str _init__.:Initializes the reviewed list to empty list.
Calls the private method set_password that assigns the value of the first letter from the value of each attribute of the location object followed by the integer value of the age or if there is no value of the age. set_password Bookdataset Attributes: instance attributes representing the lists: books, and users. Methods: _init_. for the first time you run your program, it constructs the book objects using the data in the Books.csv file and saves them in the books list as well as writes them to book.dat file. In subsequent runs, it loads book list with the books objects saved in the file book.dat. The same applies to the user objects.
load_books: uses the data in the file Book.csv to create objects of Book and save it in the list books. load_users: uses the data in the file User.csy to create objects of User and save it in the list users. .init_rating: uses the data in the file Review_small.csv to calculate the average rating and rating_count for each book in the list books and assigns it to the rating and rating_count attributes of that book. init_reviewed: uses the data in the file Review_small.csy to find the books that have been reviewed by each user in the list users and add them to the reviewed list attribute of that user.
load_objs: reads the objects stored in book dat and append them in the books list. It also reads the objects stored in users.dat and append them to the users list. store_objs: saves in books.dat the book objects of the books list. It also saves in users.dat the user objects of the books list
Search_books: it can receive any combination of values of a book's attributes and returns the matching book objects from the books list.
Search_users: it can receive any combination of values of a user's attributes and returns the matching user objects from the users list.
Sort_books: it can sort a books list using any of the books attributes. 2. Code the following class below in the file gui.py GUI Attributes private instance attributes representing admin_username, admin_password, and bookdataset which is an object of the Bookdataset class. Methods
All it takes to design this GUI and have it functioning
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started