(Source code attached) Django Piano Yin and Yang Graduation Project 31602

Development of Django piano yin and yang system

Summary

The piano is a keyboard instrument derived from Western classical music and is commonly used for solo, ensemble, accompaniment and other performances. Among thousands of ancient and modern musical instruments in various countries around the world, the modern piano is hailed as the "King of Musical Instruments" by many musicians. This is not only because of its largest size and the most complex internal structure, but also because of its excellent quality. The comprehensive performance and wide range of uses are unmatched by other musical instruments. The theory of yin and yang is the mother of the Chinese philosophical system. The classic ancient Chinese philosophy "Book of Changes" tells us that the movement of yin and yang is the law of movement of all things. The balance of yin and yang means that the growth and decline of yin and yang are coordinated, neither excessive nor too weak, showing a coordinated state. Everything in the world is inseparable from the unity of opposites of yin and yang.

This article designs a piano yin and yang system. The system functions include piano information, teaching material information, music library information, track statistics, voice recognition, feedback, etc. Users can not only view information conveniently and quickly, but also search for their favorite piano tracks and Textbook information, etc. The Piano Yin Yang system adopts an object-oriented development model for software development and hardware installation, which can well meet the needs of actual use. It has improved the corresponding software installation and program coding work, and uses MySQL as the main storage of back-end data. The unit uses the Django framework and Python programming language to code and develop the business system, realizing all functions within the system. This report first analyzes the background, role, and significance of the research, laying the foundation for the rationality of the research work.

Keywords: Piano Yin and Yang; Django framework; MySQL database

Development of Django Piano Yin and Yang System

Abstract

Piano is a keyboard instrument derived from western classical music, which is widely used in solo, ensemble, accompaniment and other performances. Among thousands of ancient and modern musical instruments all over the world, the modern piano is known as the "king of musical instruments" by many musicians, not only because of its largest volume and the most complex internal structure, but also because of its excellent and comprehensive performance and extensive use, which are incomparable with other musical instruments.The theory of yin and yang is the mother of the Chinese philosophy system. The great classic of ancient Chinese philosophy, The Book of Changes, tells us that the movement of yin and yang is the movement law of all things. The balance of yin and yang means that the growth and decline of both sides of yin and yang are kept in harmony, neither excessive nor partial. It presents a state of coordination. Everything in the world cannot be separated from the unity of opposites of yin and yang.

This paper designs a piano yin and yang system. The system functions include music information, teaching material information, music library information, track statistics, voice recognition, opinion feedback, etc. Users can not only easily and quickly view information, but also search their favorite piano tracks and teaching material information. The Piano Yin and Yang system adopts the object-oriented development mode for software development and hardware installation, which can well meet the actual use needs, improve the corresponding software installation and program coding work, take MySQL as the main storage unit of background data, use Django framework and Python programming language for business system coding and development, and realize all functions in the system. This report first analyzes the background, role and significance of the research, laying a foundation for the rationality of the research work。

Key words:Piano Yin and Yang; Django framework; MySQL database

Table of contents

Chapter 1 Introduction

1.1 Research background and significance

1.2Research status 

1.3论文组结瞄 

Chapter 2 Introduction to related technologies

2.1 Opening technique explanation3

2.2 Mysql number installation3

2.3 Python introduction4

2.4 Django stile4

2.5 Working Principle of B/S System4

Chapter 3 System Analysis

3.1 Feasibility analysis

3.2 Functional Requirements Analysis

3.2.1 Front-end user function

3.2.2 Backend administrator function

3.3 Non-functional requirements analysis

3.4 Security Requirements Analysis

3.4.1 Systematic safety

3.4.2 Data Security

3.5 ​Several flow analysis

Chapter 4 System Design

4.1 System structure design

4.2 Overall system design

4.3 统统 Functionality设计

4.4 Database Design

4.4.1 Data requirements analysis

4.4.2 Database conceptual design

4.4.3 Database table design

Chapter 5 System Implementation

5.1 Implementation of registration module

5.2 Implementation of login module

5.3 Implementation of user data modification module

5.4Music LibraryImplementation of Management Module 

5.5Piano InformationModule Implementation 

5.6Textbook Information ManagementImplementation of Module 

Chapter 6 System Testing

6.1 Purpose of exam

6.2 ability test

6.3 Performance test

Chapter 7 Summary and Outlook

references

Acknowledgments

  1. introduction
    1. research background and meaning

With the rapid development of the Internet, people have entered the information age. The Web has had a profound impact on commerce, industry, banking, finance, education, government, entertainment and information industries, as well as people's work and life. Many traditional information and database systems are being transplanted to the Internet. The sources of information for people are no longer just traditional media such as newspapers, television, and radio. A new information transmission media is gradually being favored by people. A wide range of complex distributed applications are emerging in the Web environment. As a product of the new era of media, the Piano Yin Yang System has long transcended national borders. Users can search various piano music libraries, query textbook information and perform voice recognition online. It abandons the shortcomings of traditional music media and is moving forward rapidly. develop.

With the advent of the Internet age, the advantages and popularity of the Internet are constantly affecting and changing people's lifestyles. Today, with the rapid development of information technology, computer technology has spread all over the world, causing huge changes in society.

    1. Research status

With the continuous development of the domestic economic situation, China's Internet has entered a rare period of peak development, which has caused Chinese and foreign capitalists to turn to the Internet market. However, the unreasonable structure, shortage of personnel, and increased management needs in many management fields have made more people aware of Internet management.

In today's highly developed information, information management reform has become a more extensive and comprehensive trend. The piano yin and yang system is based on the Mysql database and is implemented on the basis of the Python development language design. How to use convenient and fast methods to query, store, manage and share music library information in the vast piano yin and yang system has important practical significance for our study, work and life. Therefore, academic circles at home and abroad have conducted in-depth and extensive research on this issue.

    1. Thesis structure

Based on the information data obtained from market research and using relevant system development and design methods, the piano yin and yang system was finally designed.

This article has seven chapters in total, as shown below.

The first chapter outlines the research purpose and significance of the piano yin and yang system, and finally gives the structure of the paper.

Chapter 2 provides a brief overview of the development techniques and tools used in this article.

Chapter 3 briefly conducts demand analysis and feasibility analysis on each business process of the system.

Chapter 4 designs the piano yin and yang system.

Chapter 5 implements the piano yin and yang system, and posts screenshots of relevant pages, describing the operation methods of specific functions in language.

Chapter 6 uses test cases to test some main functional modules of the piano yin and yang system, and finally obtains the test results.

Chapter 7 summarizes the full text and makes an outlook for future research.

  1. Introduction to related technologies
    1. Development technical description:

The front-end part of this system is developed based on the MVVM model, using the B/S mode, and the back-end part is developed based on the python Django framework.

Front-end part: The front-end framework uses the popular progressive PythonScript framework Vue.js. Use Vue-Router and Vuex to realize dynamic routing and global state management, Ajax to realize front-end and back-end communication, Element UI component library to quickly prototype the page, and the project front-end to achieve responsiveness through grid layout, which can be adapted to PC, tablet, mobile phone, etc. Perfect layout display for different screen sizes.

Back-end part: Use Django as the development framework and integrate Redis and other related technologies.

    1. Mysql database

Mysql is a multi-user, multi-thread server that uses SQL database. The database management system is based on the relationship between SQL users and server modes. Its advantages include powerful functions, simple operation, convenient management, reliability and security, and fast operation. , multi-threading, cross-platform, fully networked, stable, etc., it is very suitable for the development of Web sites or other application software in the database back-end. In addition, using many languages, members can write and access MySQL database programs. Mysql database is also open source. Developers are increasingly fond of using Mysql relational database, and its application scope has also been extended. Because of its speed and ease of use, it is also used in the development of database backends for Web sites or application software.

The mysql database has many advantages, such as its easy-to-understand operation, powerful functions, and high information storage capacity. Therefore, it is widely used by people. For mysql database, it is generally mainly used for encoding and querying data, and it is applied to this database in many designs. In this process, we can query and combine conventional data, so When we use the mysql database, we only need to write a small piece of data to achieve the corresponding function. A database is a storage room for data storage, but the data is stored on a computer instead of a real storage room. The data is stored in a fixed format, not disordered. The definition is: a fixed format for a long time. Storage on computer memory that can be shared. Database management mainly includes the establishment of data tables, data storage, modification and addition of data. In order to ensure that the database system can operate normally, the management work carried out by relevant personnel. The establishment of the data table can adjust the data in the data table, recombine and reconstruct the data to ensure the security of the data.

2.3 ​Python introduction

Python is a high-level scripting language that combines interpreted, compiled, interactive, and object-oriented programming. Python's design, compared to other languages ​​that often use English keywords and some punctuation marks from other languages, has a more distinctive grammatical structure than other languages ​​and is highly readable.

Interpreted languages: Similar to Python and Perl languages, this means that there is no compilation link in the development process.

Interactive languages: Code can be executed directly from a Python prompt >>>.

Object-oriented language: Python supports object-oriented style or programming techniques in which code is encapsulated in objects

2.4 DjangoStile

1.Spring’s advantages:

Through Spring's IOC feature, the dependencies between objects are controlled by Spring, which facilitates decoupling and simplifies development.

2. Advantages of Spring MVC:

SpringMVC is a lightweight web framework that uses MVC design ideas to decouple the web layer, making our development more concise .

3. Advantages of Mybatis:

Database operations (sql) use xml file configuration, decoupling sql and code, provides mapping tags, supports objects and The database ORM field relationship mapping supports object relationship mapping tags, supports the establishment of object relationships, provides xml tags, and supports dynamic sql.

2.5 Working principle of B/S system:

The B/S architecture adopts the working mode of browser request and server response.

Users can access text, data, pictures, animations, video on demand, sounds and other information generated by Web servers on the Internet through a browser;

Each Web server can be connected to the database server in various ways, and a large amount of data is actually stored in the database server;

Download the program fromWeb service to the local computer for execution. During the download process, if any instructions related to the database are encountered, the program will be executed by the Web server. The server hands it to the database server for interpretation and execution, and returns it to the Web server, which in turn returns it to the user. In this structure, many networks are connected together to form a huge network, that is, the global network. Each enterprise can build its own Internet based on this structure.

In the B/S mode, the user requests access through the browser to many servers distributed on the network. The browser's request is processed by the server, and the processing results and corresponding information are returned to the browser. Other data All processing and requests are completed by the Web Server. Through this framework structure and the browser embedded inside the operating system, this structure has become the mainstream structure pattern of today's software applications.

  1. system analysis
    1. Feasibility Analysis

When developing any system, its feasibility must be analyzed and its time and resource constraints must be considered, which can reduce the risks of system development. At the same time, after analysis, not only can manpower be used rationally, but also the consumption of various resources can be saved. The following will introduce the three aspects of technology, economy and society.

In terms of practicality, the main task of this design is to implement functional modules such as music information, teaching material information, music library information, track statistics, speech recognition, and feedback in the piano Yin and Yang system, which is in line with the current trend of development. From the user's perspective, we also consider system operating costs and human resources, and use convenient methods on the Internet to implement online business, making the business process more systematic, more user-friendly, and more practical.

In terms of economy, the main purpose of the piano yin and yang system designed in this project is to provide more convenient and faster repertoire search and playback services, that is, information software that can be directly put into use. The main cost of the system is mainly concentrated on the subsequent maintenance and management update of usage data. However, once the system is put into actual operation and use, it can greatly improve the efficiency of information query and retrieval. At the same time, it is also necessary to effectively ensure the security of the queryer's information. At the same time, the practical application brought by this accompaniment sharing The value far exceeds the cost of developing and maintaining the actual system, so it is economically feasible to develop this software.

    1. Functional requirements analysis

The functions of the piano yin and yang system are mainly divided into front-end users registering and logging in according to their own needs, browsing piano information, recommending music library information, downloading teaching materials, speech recognition playback, etc. The backend system administrator mainly manages detailed information such as registered users, information data, teaching material information, music library information, track statistics, speech recognition, feedback, etc.

The user use case diagram is shown below.

Figure 3-1 User use case diagram

The administrator use case diagram is shown below.

               

Figure 3-2 Administrator use case diagram

      1. Front-end user function

The functions of registered users at the front desk are as follows:

Registration and login: The user fills in personal information and verifies the mobile phone number to register the account. After successful registration, the user can log in to the system.

Piano information: Users can search for information online, view piano information, etc.

Music library information: Users can search for their favorite piano music information.

Maintaining personal information: Users can modify their registration information at any time due to changes in personal information.

Teaching material information: Users can query piano teaching material information online and download teaching material attachments for learning.

Speech recognition: Users can upload a certain piano piece for system recognition, and view recognition result information, etc.

Feedback: Users can submit feedback online.

      1. Backend administrator function

Administrator functions are as follows:

Change password: Administrators can change their login password to enter the system at any time to ensure system security.

User management: maintain and manage registered user information, etc.

Piano information management: Maintain piano information, add, delete, and modify information.

Music library management: Publish music library information.

Teaching material information management: Entry management of teaching material information.

Speech recognition management: Recognize and manage speech.

Feedback management: reply to users’ feedback.

Content management, etc.

    1. Non-functional requirements analysis

First of all, the main consideration is whether the system functional software can better meet the basic functional needs of various users in the specific design process. If it cannot better meet the user needs, then the existence of this system is of no value. The non-functional analysis of software systems is carried out from seven aspects: one is performance analysis, which is aimed at the system; one is security analysis, which is aimed at the system; one is integrity analysis, which is aimed at the system; one is maintainability analysis, which is aimed at the system; One is scalability analysis, targeting the system, and the other is performance analysis to adapt to the business. After a comprehensive comparison and analysis of the performance of the piano yin and yang system in seven aspects including performance, security, expansion, and integrity, it was found that corresponding non-functional requirements analysis is needed.

    1. Security requirements analysis
      1. System security

Security is very important for every system. A system with good security can protect corporate information and user information from being stolen. Improving system security is not only a responsibility to users. Especially for the piano yin and yang system, there must be good security to protect the entire system.

The system has permission control for users, and restricts users' permissions based on different roles to ensure the security of the system.

      1. Data security

The data in the database is input from the outside world. When the data is input, due to various reasons, the input data will be invalid or dirty data. Therefore, how to ensure that the input data complies with regulations has become the primary concern of database systems, especially multi-user relational database systems.

Therefore, when writing to the database, data integrity, correctness and consistency must be ensured.

    1. Data flow analysis

After analyzing the data flow of the system, the users of the system are divided into two categories: general users and administrators. The system mainly handles interface information transmission, login information verification, registration information reception, and responses to various user operations.

The top-level data flow diagram of the system is shown in the figure below.

Figure 3-2 Top-level data flow diagram

To determine the identity of the user, it is judged based on the login data and then jumps to the corresponding functional interface. Users within the system can operate the data, and the database center can receive the effective data stream transmitted by the system to perform corresponding operations on the data SQL statements.

The underlying data flow diagram of the system is shown in the figure below.

 Figure 3-3 Underlying data flow diagram

The system can be divided into two parts: the frontend and the backend. After each operation, the system returns the operation results. The data connection between the front-end and the back-end is mainly through the database, which means different operations are performed on the database respectively.

  1. system design
    1. System architecture design

The architectural design of the Piano Yin Yang system is mainly divided into three layers, mainly the Web layer, the business layer, and the Model layer. The web layer also includes the View layer and the Controller layer, and the Model layer includes the metadata extension layer and the data access layer.

The system architecture is shown in the figure below.

MVVM abstracts the state and behavior of the View, allowing us to separate the view UI and business logic. Of course, ViewModel has already done these things for us. It can take out the Model data and help handle the business logic involved in the View that needs to display content. It compulsorily separates the input, output and processing of the application and divides it into three core parts, each of which has different functions.

Figure 4-1 System architecture diagram

View layer View refers to the interface that users can see and interact with. Views can display relevant data to users and receive data input by users, but they do not perform any actual business operations on user data.

The model layer processes the data passed by the view layer through the control layer. The same model can provide data to different views and can also be reused by different views. Since the main content of Model is data, methods and behaviors, it is also the part with the most complex logic and the largest amount of code in MVVM. It contains many business logic that needs to be used in applications, so the development of the model layer has become particularly important. In the later stage, large-scale changes are generally not made to the model layer, which is also the most stable part of MVVM. The control layer is mainly responsible for data transmission and processing request operations between the view layer and the model layer. When the user sends data and requests through the view, the control layer can receive the request and data and decide which models to call and which operations of the model to process the data and requests. After the processing is completed, the control layer returns the data to the corresponding view.

    1. Overall system design

The Piano Yin Yang system is generally divided into a front-end user module and a back-end administrator module.

The two modules appear to exist independently, but the database they access is the same. The functions of each module are compiled and produced based on previously completed demand analysis and review of relevant information.

To sum up, the flow chart of system function development is shown in the figure below.

Figure 4-2 Flow chart of system function development

    1. System functional design

Login module: The login module is the entrance to the system. All users must log in before they can access the system. You need to enter your username and password to log in. If you try to log in multiple times, you need to enter a verification code. When logging in, you need to select the user's role, whether it is a general user or administrator login, etc. After successful login, the user's permissions will be obtained through the database and jumped to the user's home page.

Music library information module: It can be divided into three modules: browsing, retrieval, and maintenance. Administrators have the authority to maintain music library information, publish new music library information, etc.

Piano information management module: for publishing piano information operations, etc.

    1. Database Design
      1. Data requirements analysis

From the previous analysis, we can see that the most important things in the database are music library information, teaching material information, speech recognition, feedback, and information browsing. The analysis can obtain the following data description:

Platform users: used to record various user information, including name, mobile phone, email, photos and other data items.

Administrator: Record the administrator’s login information. Including username, password, permissions and other data items.

Textbook information: Store information data items for various types of textbooks.

Piano information: stores piano information and other data items.

Music library information: System music library management.

Speech recognition management: Manage users’ speech recognition and other data items.

Feedback management: reply to users’ feedback information.

      1. Database concept design

According to the previous data flow chart and combined with the functional module design of the system, each information entity that conforms to the system is designed.

The system ER diagram is shown below.

Figure 4-3 System ER diagram

      1. Database table design

The data tables owned by the Piano Yin Yang system include the following: user information table, information information table, music library information table, teaching material information table, track statistics table, speech recognition table, feedback table, etc.

Due to the large number of data tables, only the main data tables of the system are shown, as shown in the following table.

Table auth (user rights management)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

auth_id

int

10

0

N

AND

Authorization ID:

2

user_group

varchar

64

0

AND

N

user group:

3

mod_name

varchar

64

0

AND

N

Module name:

4

table_name

varchar

64

0

AND

N

Table Name:

5

page_title

varchar

255

0

AND

N

page title:

6

path

varchar

255

0

AND

N

Routing path:

7

position

varchar

32

0

AND

N

Location:

8

mode

varchar

32

0

N

N

_blank

Jump method:

9

add

tinyint

3

0

N

N

1

Is it possible to add:

10

of the

tinyint

3

0

N

N

1

Can it be deleted:

11

set

tinyint

3

0

N

N

1

Whether it can be modified:

12

get

tinyint

3

0

N

N

1

Is it possible to view:

13

field_add

text

65535

0

AND

N

Add fields:

14

field_set

text

65535

0

AND

N

Modify fields:

15

field_get

text

65535

0

AND

N

Query fields:

16

table_nav_name

varchar

500

0

AND

N

Cross-table navigation name:

17

table_nav

varchar

500

0

AND

N

Cross-table navigation:

18

option

text

65535

0

AND

N

Configuration:

19

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

20

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

table collect (collection)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

collect_id

int

10

0

N

AND

Collection ID:

2

user_id

int

10

0

N

N

0

Collector ID:

3

source_table

varchar

255

0

AND

N

Source table:

4

source_field

varchar

255

0

AND

N

Source field:

5

source_id

int

10

0

N

N

0

Source ID:

6

title

varchar

255

0

AND

N

title:

7

img

varchar

255

0

AND

N

Cover:

8

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

9

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

Table comment (comment)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

comment_id

int

10

0

N

AND

Comment ID:

2

user_id

int

10

0

N

N

0

Commenter ID:

3

reply_to_id

int

10

0

N

N

0

Reply comment ID: empty is 0

4

content

longtext

2147483647

0

AND

N

content:

5

nickname

varchar

255

0

AND

N

Nick name:

6

avatar

varchar

255

0

AND

N

Avatar address: [0,255]

7

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

8

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

9

source_table

varchar

255

0

AND

N

Source table:

10

source_field

varchar

255

0

AND

N

Source field:

11

source_id

int

10

0

N

N

0

Source ID:

Table feedback (feedback)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

feedback_id

int

10

0

N

AND

Feedback ID

2

user_information

int

10

0

AND

N

0

User Info

3

user_name

varchar

64

0

AND

N

username

4

contact_information

varchar

64

0

AND

N

Contact information

5

feedback_date

date

10

0

AND

N

Feedback date

6

feedback_content

text

65535

0

AND

N

Feedback content

7

recommend

int

10

0

N

N

0

Intelligent Recommendation

8

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

9

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

Table hits (user clicks)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

hits_id

int

10

0

N

AND

Like ID:

2

user_id

int

10

0

N

N

0

Liked by:

3

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

4

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

5

source_table

varchar

255

0

AND

N

Source table:

6

source_field

varchar

255

0

AND

N

Source field:

7

source_id

int

10

0

N

N

0

Source ID:

Table library_information (music library information)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

library_information_id

int

10

0

N

AND

Music library information ID

2

track_title

varchar

64

0

AND

N

Track name

3

english_name

varchar

64

0

AND

N

English name

4

qufeng_type

varchar

64

0

AND

N

genre type

5

performer

varchar

64

0

AND

N

player

6

english_name_of_performer

varchar

64

0

AND

N

Performer's English name

7

track_details

text

65535

0

AND

N

Track details

8

track_cover

varchar

255

0

AND

N

track cover

9

track_audio

varchar

255

0

AND

N

track audio

10

hits

int

10

0

N

N

0

Clicks

11

praise_len

int

10

0

N

N

0

Number of likes

12

recommend

int

10

0

N

N

0

Intelligent Recommendation

13

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

14

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

Notice (announcement)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

notice_id

mediumint

8

0

N

AND

Announcement id:

2

title

varchar

125

0

N

N

title:

3

content

longtext

2147483647

0

AND

N

text:

4

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

5

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

Table ordinary_users (ordinary users)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

ordinary_users_id

int

10

0

N

AND

Common user ID

2

user_name

varchar

64

0

AND

N

username

3

user_gender

varchar

64

0

AND

N

User gender

4

examine_state

varchar

16

0

N

N

passed

Approval Status

5

recommend

int

10

0

N

N

0

Intelligent Recommendation

6

user_id

int

10

0

N

N

0

User ID

7

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

8

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

Express praise (like)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

praise_id

int

10

0

N

AND

Like ID:

2

user_id

int

10

0

N

N

0

Liked by:

3

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

4

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

5

source_table

varchar

255

0

AND

N

Source table:

6

source_field

varchar

255

0

AND

N

Source field:

7

source_id

int

10

0

N

N

0

Source ID:

8

status

bit

1

0

N

N

1

Like status: 1 is like, 0 is canceled

Table slides (carousel)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

slides_id

int

10

0

N

AND

Carousel image ID:

2

title

varchar

64

0

AND

N

title:

3

content

varchar

255

0

AND

N

content:

4

url

varchar

255

0

AND

N

Link:

5

img

varchar

255

0

AND

N

Carousel image:

6

hits

int

10

0

N

N

0

Number of clicks:

7

create_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Creation time:

8

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time:

Table speech_recognition (speech recognition)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

speech_recognition_id

int

10

0

N

AND

Voice recognition ID

2

user_information

int

10

0

AND

N

0

User Info

3

user_name

varchar

64

0

AND

N

username

4

upload_audio

varchar

255

0

AND

N

Upload audio

5

upload_date

date

10

0

AND

N

Upload date

6

identification_results

text

65535

0

AND

N

Recognition results

7

recommend

int

10

0

N

N

0

Intelligent Recommendation

8

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

9

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

Table textbook_information (textbook information)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

textbook_information_id

int

10

0

N

AND

Textbook information ID

2

name_of_textbook

varchar

64

0

AND

N

Textbook name

3

english_name

varchar

64

0

AND

N

English name

4

type_of_textbook

varchar

64

0

AND

N

Textbook type

5

number_of_textbooks

varchar

64

0

AND

N

Number of textbooks

6

textbook_details

text

65535

0

AND

N

Textbook details

7

cover_of_textbook

varchar

255

0

AND

N

Textbook cover

8

textbook_track

varchar

255

0

AND

N

Textbook repertoire

9

textbook_attachments

varchar

255

0

AND

N

Textbook attachments

10

hits

int

10

0

N

N

0

Clicks

11

praise_len

int

10

0

N

N

0

Number of likes

12

recommend

int

10

0

N

N

0

Intelligent Recommendation

13

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

14

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

Table track_statistics (track statistics)

serial number

name

type of data

length

Decimal places

Allow null values

primary key

default value

illustrate

1

track_statistics_id

int

10

0

N

AND

Track statistics ID

2

track_title

varchar

64

0

AND

N

Track name

3

track_classification

varchar

64

0

AND

N

Track classification

4

difficulty_level

varchar

64

0

AND

N

difficulty level

5

number_of_trainees

varchar

64

0

AND

N

Number of people practicing

6

exercise_paragraph_length

varchar

64

0

AND

N

Practice paragraph length

7

practice_the_whole_song_length

varchar

64

0

AND

N

Practice the whole song duration

8

total_duration

varchar

64

0

AND

N

total duration

9

recommend

int

10

0

N

N

0

Intelligent Recommendation

10

create_time

datetime

19

0

N

N

CURRENT_TIMESTAMP

creation time

11

update_time

timestamp

19

0

N

N

CURRENT_TIMESTAMP

Update time

  1. System implementation
    1. Implementation of registration module

用户在填写数据的时候必须与注册页面上的验证相匹配否则会注册失败,注册页面的表单验证是通过验证的,用户名的长度必须在6到18之间,邮箱必须带有@符号,密码和密码确认必须相同,你输入的密码,系统会根据你输入密码的强度给出指定的值,电话号码和身份证号码必须要求输入格式与生活相符合,当你前台验证通过的时候你点击注册,表单会将你输入的值通过name值传递给后台并保存到数据库中。

用户注册流程图如下图所示。

图5-1用户注册流程图

用户注册界面如下图所示。

图5-2用户注册界面

    1. 登录模块的实现

主要由两部分组成,登录前的登录界面以及登录后的用户功能界面。登录界面,要求用户输入用户名和密码,当用户名和密码其中一个输入为空时,给出提示“用户名,密码不能为空”。获取用户名和密码后到数据库中查找,如果用户名存在,以及对应的密码正确,则登录成功,否则登录失败。登录失败后给出提示,并把焦点停在文本框中。登录成功后将该次会话的全局变量username设置为用户名。登录成功后进入会员的功能模块,主要有会员基本信息修改,已经发布考试信息管理,发布信息,和退出功能。退出功能是清除全局变量username的值,并跳回到首页。

登录流程图如下图所示。

图5-3登录流程图

用户登录界面如下图所示。

图5-4用户登录界面

    1. 用户资料修改模块的实现

用户登录/注册成功之后可以修改自己的基本信息。修改页面的表单中每一个input的name值都要与实体类中的参数相匹配,在用户点击修改页面的时候,如果改后用户名与数据库里面重复了,页面会提示该用户名已经存在了,否则通过Id来查询用户,并将用户的信息修改为表单提交的数据。

    1. 曲库管理模块的实现

如果曲库信息需要修改,管理员可以通过查询曲目名或者类型来查询曲库信息,查询曲库是通过ajax技术来进行查询的,需要传递曲目名称、曲风类型等参数然后在返回到该页面中,可以选中要修改或删除的那条信息,如果选中了超过一条数据,页面会挑一个窗口提醒只能选择一条数,如果没有选中数据会挑一个窗口题型必须选择一条数据。当选择确认修改的时候,后台会根据传过来的id到数据库查询,并将结果返回到修改页面中,可以在修改页面中修改刚刚选中的信息当点击确认的时候from表单会将修改的数据提交到后台并保存到数据库中,就是说如果提交的数据库中存在就修改,否则就保存。

曲库管理界面如下图所示。

图5-5曲库管理界面

    1. 钢琴资讯模块的实现

钢琴资讯功能需要考虑高并发,防止出现钢琴资讯重复、钢琴资讯状态显示出错等情况,特对钢琴资讯这一共享数据增加锁机制。在乐观锁、悲观锁以及线程锁中,综合考虑性能效率和错误的可接受性选择了乐观锁机制。乐观锁的实现方式是使用版本标识来确定读到的数据与提交时的数据是否一致,提交后修改版本标识,不一致时可以采取丢弃和再次尝试的策略。在数据库钢琴资讯表(对应钢琴资讯实体)设计中增加了version字段,每次数据提交时(更改钢琴资讯状态)会判断version是否匹配,若不匹配停止本次提交,若匹配则提交成功并增加version的值。

钢琴资讯功能整体流程:用户浏览钢琴资讯信息时,同时会显示钢琴资讯的状态,系统会在其显示详细信息的页面时便会判断钢琴资讯的状态,若钢琴资讯状态为可浏览,则会显示搜索的链接按钮。在用户点击搜索按钮时,会先通过拦截器判断用户是否登录,若未登录,会跳转至登录页面,提示用户先登录,若为登录用户就会跳转至填写信息的页面,填写好信息之后,点击搜索按钮,成功之后显示出钢琴资讯。

钢琴资讯流程图如下图所示。

图5-6钢琴资讯流程图

钢琴资讯界面如下图所示。

图5-7钢琴资讯界面

    1. 教材信息管理模块的实现

此页面的关键是编写教材信息,包括教材信息详情等。单击提交按钮以完成信息的添加。如果未加入完整的教材信息,例如,如果未上传教材附件,系统将给出相应的错误提示,并且无法成功输入。数据以概念的形式以onsubmit =“return checkForm()”的形式写入以进行检查,checkForm()函数是一种用于写入数据的不同类型的校对方法,是不是为空也是经过form表单中的οnsubmit=”return checkForm()来检查。

管理员点击左侧菜单“教材信息管理”,页面跳转到教材信息管理外观,调用后台教材信息查询所有教材。并将信息密封到数据集合List,绑定到请求对象,然后页面跳转到相应的界面,显示出教材信息,单击删除按钮完成信息的删除。

教材信息管理流程图如下图所示。

图5-8教材信息管理流程图

教材信息管理界面如下图所示。

图5-9教材信息管理界面

  1. 系统测试
    1. 测试目的

对任何系统而言,测试都是必不可少的环节,测试可以发现系统存在的很多问题,所有的软件上线之前,都应该进行充足的测试之后才能保证上线后不会Bug频发,或者是功能不满足需求等问题的发生。下面分别从单元测试,功能测试和用例测试来对系统进行测试以保证系统的稳定性和可靠性。

    1. 功能测试

下表是曲库管理功能的测试用例,检测了曲库管理中对曲库信息的增加,删除,修改,查询操作是否成功运行。观察系统的响应情况,得出该功能也达到了设计目标,系统运行正确。

前置条件;用户登录系统。

表6-1 曲库管理的测试用例

功能描述

用于曲库管理

测试目的

检测曲库管理时的各种操作的运行情况

测试数据以及操作

预期结果

实际结果

点击添加曲库,必填项合法输入,点击保存

提示添加成功

与预期结果一致

点击添加曲库,必填项输入不合法,点击保存

提示必填项不能为空

与预期结果一致

点击修改曲库,必填项修改为空,点击保存

提示必填项不能为空

与预期结果一致

点击修改曲库,必填项输入不合法,点击保存

提示必填项不能为空

与预期结果一致

点击删除曲库,选择曲库删除

提示删除成功

与预期结果一致

点击搜索曲库,输入存在的曲库名

查找出曲库

与预期结果一致

点击搜索曲库,输入不存在的曲库名

不显示曲库

与预期结果一致

下表是教材管理功能的测试用例,检测了教材管理中对教材信息的增加,删除,修改,查询操作是否成功运行。观察系统的响应情况,得出该功能也达到了设计目标,系统运行正确。

前置条件;用户登录系统。

表6-2 教材信息管理的测试用例

功能描述

用于教材信息管理

测试目的

检测教材信息管理时的各种操作的运行情况

测试数据以及操作

预期结果

实际结果

点击添加教材信息,必填项合法输入,点击保存

提示添加成功

与预期结果一致

点击添加教材信息,必填项输入不合法,点击保存

提示必填项不能为空

与预期结果一致

点击修改教材信息,必填项修改为空,点击保存

提示必填项不能为空

与预期结果一致

点击修改教材信息,必填项输入不合法,点击保存

提示必填项不能为空

与预期结果一致

点击删除教材信息,选择教材信息删除

提示删除成功

与预期结果一致

点击搜索教材信息,输入存在的教材信息名

查找出教材信息

与预期结果一致

点击搜索教材信息,输入不存在的教材信息名

不显示教材信息

与预期结果一致

下表是发布内容管理功能的测试用例,检测了发布内容管理中分类列表的操作是否成功运行。观察系统的响应情况,得出该功能也达到了设计目标,系统运行正确。

前置条件;用户登录系统。

表6-3 发布内容管理的测试用例

功能描述

用于发布内容管理

测试目的

检测发布内容管理时各种操作的情况

测试数据以及操作

预期结果

实际结果

未选择分类,点击提交

提示请选择分类

与预期结果一致

未选择列表,点击提交

提示请选择列表

与预期结果一致

    1. 性能测试

使用阿里云PTS(Performance Testing Service)性能测试服务对线上系统进行压力测试。线上服务器环境为:1核心CPU,1G内存,1Mbps公网带宽,Centos7.0操作系统。

During the stress test, 2 concurrent machines were used, with 20 concurrent users on each machine. The system home page, login, data query and data maintenance modules were accessed concurrently. The test result was that when there were 40 concurrent users, the data management related pages The response time even reached 7s. By checking the server's outbound traffic, it was found that it had reached 1381kb/s. It can be seen that the server's bandwidth has reached its peak. If the system uses 5Mbps bandwidth, the system's response time and TPS will be greatly increased. During the entire test, the CPU usage was only 8%, which also showed that the bandwidth bottleneck had a serious impact on the system.

  1. Summary and Outlook

With the rapid development of computer Internet technology, all walks of life have adopted computer-related technologies to manage increasingly amplified data. This topic is developed with the core of piano music library information sharing. This study focuses on the requirements modeling, data modeling and process modeling of the piano yin and yang system to analyze, design and implement the platform research process. Provide the system application architecture and analyze the advantages and disadvantages, and describe the functional requirements through functional decomposition diagrams and system component diagrams. Designed and established a database, and defined the key data structures of the system. Describe the collaboration relationships between components through class diagrams, and give the definition methods of each class. Implement the front-end and back-end code of the system by describing the fields, attributes and methods of each class. Finally, a system integration method is given to complete the design and implementation of the piano yin and yang system. When the system is put into operation, all functions are running normally. The operation of each interface of the system conforms to conventional logic, making it simple to operate and user-friendly. Each function of the entire system is reasonably designed and reflects humanization.

However, due to my insufficient grasp of some relevant knowledge and technologies used in the system development process, coupled with my lack of development experience, the system's functions in some aspects are not perfect enough and the considerations are not comprehensive enough. Therefore, the entire system still needs to be It will be gradually improved in the future.

references

[1] Huo Fuhua, Han Hui. MVVM model of front-end and back-end separation based on SpringBoot microservice architecture [J]. Electronic Technology and Software Engineering, 2022(01):73-76.

[1] Shi Wen, Sun Manman, Li Chunhui. Discussion on the application of Python language in the "Fundamentals of Programming" course [J]. The Road to Talent, 2023(03):113-116.

[2] Yu Bingjun, Guo Fen, Zhang Yongxiong, Wang Liangming. Teaching reform of Python language programming course based on OBE concept [J]. Innovation and Entrepreneurship Theory Research and Practice, 2023, 6(01): 41-43+47.

[3] Zhou Chunyin. Research on graphical user interface design based on Python language [J]. Science and Technology Innovation, 2022(35):81-85.

[4] Li Yan, Wang Qian. Exploration of paths for ideological and political construction of Python language programming courses [J]. Qinghai Education, 2022(11):55-56.

[5] Fang Lei. Analysis on scaffolded practical training teaching of Python language programming [J]. Journal of Hubei University of Arts and Sciences, 2022, 43(11):83-88.

[6] Deng Jieying. Research on the application of Python language programming in computer theory teaching [J]. Modern Information Technology, 2022, 6(21): 185-187+191.

[7] Sheng Guanqun, Zhao Meilin, Liu Zhongtu, Zheng Yuelin, Jiang Yanjing, Tang Jing. Exploration on the curriculum reform of "Python Language Programming" under the background of artificial intelligence [J]. Science and Technology Wind, 2022(30):83-85.

[8] Wang Boran. Systematic analysis of the formation of piano playing skills [J]. Times Report (Benliu), 2022(02):68-70.

[9] Gong Xuan. Research and system implementation of audio-visual fusion piano transcription technology [D]. Huazhong University of Science and Technology, 2020.

[10] Tong Zhibei. Design of piano arrangement timbre recognition system based on artificial intelligence [J]. Modern Electronic Technology, 2020, 43(04): 183-186.

[11] Chen Shizhe. Talking about the implementation method of intelligent piano software system [J]. Yuefu New Sound (Journal of Shenyang Conservatory of Music), 2019, 37(02): 109-114.

[12] Zhang Lin, Wu Jianming. Design of piano timbre recognition and electronic synthesis system based on computer technology [J]. Automation and Instrumentation, 2018(10):79-82.

[13] Zhang Jia. Innovation and optimization of piano teaching system for music majors in comprehensive colleges and universities [J]. Drama House, 2018(15):206.

Acknowledgments

This design took 3 months. In this graduation project, it is inseparable from the guidance of the instructor to make things basically smooth. The instructors gave me great help both in the graduation project experience and in completing the thesis. On the other hand, I have benefited a lot from the teachers' serious and responsible work attitude, cautious teaching spirit and solid theoretical standards. His diligent and cautious teaching, educating and learning attitude also left a very deep impression on me. I learned a lot from my teachers. My skills have been greatly improved in theory and practice. Here, I would like to express my sincere gratitude to the teachers.

After all the research and development of this graduation project, my system research and development has experienced special progress from requirement analysis to implementation of detailed functions to final testing and maintenance. It gave me a deeper understanding of system research and development. Now my hands-on ability to solve doubts independently has also been greatly improved. This is the best gain from this graduation project.

Finally, during the entire system development process, my classmates and friends around me gave me a lot of opinions, so I quickly confirmed the business idea of ​​the system. This time, I sincerely express my gratitude to them.

To receive the project source code for free, please follow and like + private message

Guess you like

Origin blog.csdn.net/VXbishe/article/details/134761017