Student companion relationship discovery method based on campus card swiping log

By preprocessing campus card swiping log data and time-space co-occurrence constraints, high-frequency co-occurrence student combinations are identified, and the problems of insufficient coverage and difficulty in dynamic tracking in traditional methods are solved, and dynamic discovery and management support for student peer relationships are realized.

CN120543313APending Publication Date: 2025-08-26BEIJING TECH & BUSINESS UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510628803.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-15
Publication Date
2025-08-26

AI Technical Summary

Technical Problem

The existing peer relationship identification methods mainly rely on teacher observation and scale evaluation, and there are problems such as insufficient coverage and difficulty in tracking the dynamic evolution of relationships, especially in the college student group, which cannot effectively construct the topology of social networks and continuously track relationship changes.

Method used

By preprocessing the campus card swiping log data, setting the time and space co-occurrence constraints, filtering out the student combinations that eat at the same time, and identifying the student combinations that co-occurrence at high frequency based on the co-occurrence times and the consistency of time and place, combining visualization to analyze the dynamic changes of peer relationships.

Benefits of technology

The student peer relationship discovery based on campus card swiping logs is realized, and the changes in peer relationships can be dynamically tracked, providing data support for education management, which is different from the lack of coverage and sustainability of traditional methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120543313A_ABST
    Figure CN120543313A_ABST
Patent Text Reader

Abstract

The invention relates to a campus card swiping log-based student companion relationship discovery method, which comprises the following implementation steps of: firstly, preprocessing an original campus card swiping log data set, uniquely identifying students and places, and combining card swiping records in the same time period to obtain a dining log data set; then, according to a set time-space co-occurrence constraint condition, screening out a card swiping co-occurrence record meeting the time-space co-occurrence constraint condition, and counting the card swiping co-occurrence frequency of the student pair; screening to obtain a high-frequency card swiping co-occurrence student pair data set according to a set high-frequency co-occurrence threshold value; and finally, merging student pairs with a mutual connection relationship to obtain a high-frequency card swiping co-occurrence student group data set, performing visualization for a specified student group, and analyzing a dynamic change condition of a companion relationship among multiple students in the student group. The method can effectively discover the companion relationship among the students, tracks and analyzes the dynamic change process of the companion relationship along with time, and provides support for improving the education management level.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of data mining under computer science, and in particular relates to a method for discovering student companion relationships based on campus card swiping logs. Background Art

[0002] Peer relationships, as a core component of students' campus social networks, have a significant impact on individual academic development, mental health, and social development. Research has shown that positive peer relationships not only enhance students' leadership and resilience but also inhibit negative behaviors such as bullying and social anxiety. Their dynamic evolution is considered a key indicator of students' social adaptability.

[0003] Currently, peer relationship identification mainly relies on two traditional methods: (1) Observational assessment method: identification is carried out through daily observation by teachers or feedback from student leaders. Although this method can capture explicit social behaviors, it has the inherent defect of insufficient coverage and it is difficult to discover potential social connections in non-public places; (2) Scale assessment method: quantitative assessment is carried out using standardized psychological measurement tools. Although it has high efficiency in evaluating relationship quality, it has two limitations: it cannot effectively construct the group-level social network topology structure, and it lacks the ability to continuously track the dynamic evolution of relationships.

[0004] It's worth noting that university students' group behavior patterns exhibit significant spatiotemporal regularities: their activities are primarily concentrated within the closed campus ecosystem of teaching areas, living quarters, and recreational venues. Their behavioral sequences are rigidly constrained by the curriculum, while also allowing for the autonomous regulation of extracurricular activities. This unique behavioral pattern often leads to a phenomenon of spatiotemporal synchronization in peer relationships, meaning that individuals with stable social connections exhibit highly coupled spatial trajectories and temporal sequences. Summary of the Invention

[0005] In view of this, the present invention provides a method for discovering student peer relationships based on campus card swiping logs. The technical solution is as follows:

[0006] Step 1: Preprocess the original campus card swiping log dataset and uniquely identify students and locations. The specific method is as follows:

[0007] The dataset used is campus card swiping log data. The dataset must contain at least the following information: the student's unique identifier, the merchant's unique identifier, and the unique identifier of the consumption time.

[0008] Step 1.1: Perform data cleaning, that is, process any missing values ​​in the data. If any missing values ​​occur, delete the row directly to avoid affecting the accuracy of the analysis.

[0009] Step 1.2: Uniquely identify students in the dining consumption card swiping log dataset. Students are uniquely identified based on their student ID number.

[0010] Step 1.3: Uniquely identify the consumption locations in the dining card consumption log dataset. Merchants merge merchants with the same consumption location based on the merchant's consumption location and uniquely identify the consumption location.

[0011] Step 2: Based on the preprocessed campus card swiping log dataset, merge the card swiping records of the same day and time period to obtain the "dining log dataset". The specific method is as follows:

[0012] Step 2.1: Based on the consumption type of the card swipe records, "non-dining card swipe records" are eliminated to improve the validity of the analysis results. The filtered card swipe logs are named "dining consumption card swipe log data set";

[0013] Step 2.2: Uniquely identify the consumption time in the dining card swipe log data set, and collect statistics on the time distribution of the card swipe records throughout the day. Based on the statistical results of the time distribution of the card swipe records, divide the time periods into breakfast, lunch, dinner, and supper;

[0014] Step 2.3: For each student's card swipe records in each time period of each day, the earliest card swipe time among multiple card swipe records in that time period is used as the "student's dining time in that time period on that day", and a unique identifier is assigned to the dining time;

[0015] After the above steps, the "dining log data set" is obtained. The content of each data in the dining log data set is shown in Table 1;

[0016] Table 1 Description of the data content of the dining log dataset

[0017]

[0018] Step 3: Set spatiotemporal co-occurrence constraints and, based on these constraints, obtain a "card swiping co-occurrence record dataset" from the dining log dataset obtained in step 2. The specific method is as follows:

[0019] Step 3.1: The spatiotemporal co-occurrence constraint for “simultaneous dining consumption events” between different students includes two parts: (1) the time difference between card swiping is within the set threshold; (2) the card swiping location is the same; that is, if two students’ dining consumption events occur at the same location during the same period and the time difference between them is within the set threshold, then the two students are considered to be “likely dining together”;

[0020] The spatiotemporal co-occurrence constraint can be described as formula (1):

[0021]

[0022] Among them, the same location condition L i =L j Ensure that the two people's dining consumption card swiping locations are exactly the same; time difference condition |T i -T j |≤τ ensures that the absolute value of the time difference between the two people's dining time does not exceed the set threshold τ; the time threshold τ can be set according to actual needs;

[0023] Students who meet the spatiotemporal co-occurrence constraints are the candidate group for "possible dining together";

[0024] Step 3.2: Based on the spatiotemporal co-occurrence constraints set in step 3.1, filter the "card swiping co-occurrence records" that meet the spatiotemporal co-occurrence constraints from the dining log dataset obtained in step 2 to form a "card swiping co-occurrence record dataset." The data content of each card swiping co-occurrence record is <student M, student N, card swiping co-occurrence date>;

[0025] Step 4: Based on the "card swiping co-occurrence record dataset" obtained in step 3, obtain the "card swiping co-occurrence student pair dataset". The specific method is:

[0026] For each student pair, the number of co-occurrence records of their card swiping is counted to obtain the co-occurrence statistics of the student pair; taking student M and student N as an example, the data content of the co-occurrence statistics of their card swiping is shown in Table 2;

[0027] Table 2 Explanation of the statistical results of the co-occurrence of card swiping in student pairs

[0028]

[0029] For all student pairs that appear in the "card swiping co-occurrence record dataset", obtain the card swiping co-occurrence statistics of the student pair to form the "card swiping co-occurrence student pair dataset";

[0030] Step 5: Based on the card swiping co-occurrence student pair dataset obtained in step 4, obtain the "high-frequency card swiping co-occurrence student pair dataset". The specific method is as follows:

[0031] Step 5.1: Count the "number of co-occurrences of card swiping" in the dataset of card swiping co-occurrence student pairs. According to the distribution characteristics of the number of co-occurrences of card swiping, set the "screening threshold for high-frequency card swiping co-occurrence student pairs"; the larger the threshold, the fewer high-frequency card swiping co-occurrence student pairs will be screened out;

[0032] Step 5.2: Filter the card swiping co-occurrence student pair dataset based on the set "Filtering threshold for high-frequency card swiping co-occurrence student pairs" and extract data with "card swiping co-occurrence times ≥ the filtering threshold for high-frequency card swiping co-occurrence student pairs" to obtain the high-frequency card swiping co-occurrence student pair dataset;

[0033] Step 6: Based on the high-frequency card swiping co-occurrence student pair dataset obtained in step 5, obtain the "high-frequency card swiping co-occurrence student group dataset". The specific method is as follows:

[0034] Step 6.1: In the dataset of high-frequency card swiping co-occurring student pairs, if the same student appears in different student pairs, the students in these pairs may form a "student group that may dine together"; select student pairs that may form a student group based on the student's unique identifier;

[0035] Step 6.2: Based on the set of student pairs that may constitute a student group, merge them according to the "mutual connection relationship of co-occurring student pairs" to obtain the "high-frequency card swiping co-occurring student group dataset";

[0036] Step 7: For the high-frequency card swiping co-occurrence student group dataset obtained in step 6, select a specific student group for visualization and analyze the dynamic changes in peer relationships among multiple students in the student group. The specific method is as follows:

[0037] Draw a line graph of the spending time of each student in the student group, using different line styles and colors to represent different students. Based on the time and space constraints, determine the peer relationships between them, and use different colors and bold marks to indicate the changes in these relationships. Taking a group of three as an example, if all three are peers on a certain day, use a single color and bold the lines. If only two of them are peers on a certain day, use the line color of any one of the students and bold it, thus intuitively showing the dynamic changes in peer relationships.

[0038] At this point, the student companion discovery method based on campus card swiping log is completed.

[0039] Beneficial effects:

[0040] Through this method, a student peer relationship discovery method based on campus card swiping logs can be realized. This is a new method different from the traditional method through teacher observation or questionnaires. It discovers the peer relationships between students based on the spatial and temporal synchronization relationship of card swiping data, and realizes the tracking and analysis of the dynamic changes of peer relationships over time, providing path support for empowering education management level based on big data. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 Flowchart of the student peer discovery method based on campus card swiping log

[0042] Figure 2 Visualization of the dynamic changes in the relationship between three people as the date changes DETAILED DESCRIPTION

[0043] The present invention will be described in detail below with reference to the accompanying drawings and examples.

[0044] Step 1: Preprocess the original campus card swiping log dataset and uniquely identify students and locations. The specific method is as follows:

[0045] The dataset used is campus card swiping log data. The dataset must contain at least the following information: the student's unique identifier, the merchant's unique identifier, and the unique identifier of the consumption time.

[0046] In this example, the campus card swiping log data of a certain university for three months is taken as an example. There are three original data sets involved, namely student data, merchant data, and transaction data. The student data file contains 6 columns of data and 30,855 rows of data. The columns are student account number account, student ID studentcode, gender gender, year of admission grade, and academic qualification type type; the merchant data file contains 4 columns of data and 134 rows of data. The columns are merchant name codename and card swiping machine number toaccount; the transaction data file contains 4 columns of data and 4,689,911 rows of data. The columns are student account number account, card swiping machine number toaccount, consumption time timestamp, and single consumption amount amount.

[0047] Step 1.1: Perform data cleaning, that is, process any missing values ​​in the data. If any missing values ​​occur, delete the row directly to avoid affecting the accuracy of the analysis.

[0048] After cleaning these three data files, the transaction data is 4,688,489 rows.

[0049] Step 1.2: Uniquely identify students in the dining consumption card swiping log dataset. Students are uniquely identified based on their student ID number.

[0050] Step 1.3: Uniquely identify the consumption locations in the dining card consumption log dataset. Merchants merge merchants with the same consumption location based on the merchant's consumption location and uniquely identify the consumption location.

[0051] Step 2: Based on the preprocessed campus card swiping log dataset, merge the card swiping records of the same day and time period to obtain the "dining log dataset". The specific method is as follows:

[0052] Step 2.1: Based on the consumption type of the card swipe records, "non-dining card swipe records" are eliminated to improve the validity of the analysis results. The filtered card swipe logs are named "dining consumption card swipe log data set";

[0053] In this example, students who enrolled in 2013 and hold a bachelor's degree have 10 consumption types: supermarkets, printing and copying, snacks and desserts, drinking water, staff cafeteria, bookstore, sports, library, bathroom, and formal meals. Obviously, formal meals, snacks and desserts, and staff cafeteria are dining consumption types, so these three consumption types are selected as screening conditions.

[0054] Step 2.2: Uniquely identify the consumption time in the dining card swipe log data set, and collect statistics on the time distribution of the card swipe records throughout the day. Based on the statistical results of the time distribution of the card swipe records, divide the time periods into breakfast, lunch, dinner, and supper;

[0055] In this embodiment, the card swipe log data of the meal type of students with undergraduate education and enrollment year of 2013 is taken as an example, and the total number of card swipes in all days of each hour is counted. The results are shown in Table 3.

[0056] Table 3 Statistics of the total number of card swipes per hour

[0057] Serial number Time period Total number of card swipes 1 0:00-1:00 0 times 2 1:00-2:00 0 times 3 2:00-3:00 0 times 4 3:00-4:00 0 times 5 4:00-5:00 247 times 6 5:00-6:00 2659 times 7 6:00-7:00 32940 times 8 7:00-8:00 67063 times 9 8:00-9:00 17,184 times 10 9:00-10:00 19222 times 11 10:00-11:00 12422 times 12 11:00-12:00 111,361 times 13 12:00-13:00 19561 times 14 13:00-14:00 369 times 15 14:00-15:00 248 times 16 15:00-16:00 590 times 17 16:00-17:00 14227 times 18 17:00-18:00 93,677 times 19 18:00-19:00 20,734 times 20 19:00-20:00 340 times 21 20:00-21:00 252 times 22 21:00-22:00 71 times 23 22:00-23:00 80 times 24 23:00-0:00 0 times

[0058] As can be seen from the table above, the number of card swipes decreases significantly after 9:00 AM, so the breakfast time period is defined as 5:00 AM to 8:00 AM. Since breakfast consumption is more dispersed in terms of space and time, we chose to analyze it within the breakfast time period.

[0059] Step 2.3: For each student's card swipe records in each time period of each day, the earliest card swipe time among multiple card swipe records in that time period is used as the "student's dining time in that time period on that day", and a unique identifier is assigned to the dining time;

[0060] After the above steps, the "dining log data set" is obtained;

[0061] In this embodiment, the process of obtaining a dining log dataset is described by taking students who enrolled in 2013 and have a bachelor's degree as an example. First, student data and transaction data are read from the original dataset, and the data of students who enrolled in 2013 and have a bachelor's degree are merged and filtered out. Then, the transaction data and merchant data are merged to filter out data with the consumption types of "main meal", "snacks and desserts", and "staff restaurant". Next, the breakfast time range is set to 5:00 to 8:00, and a dining log dataset of students who enrolled in 2013 and have a bachelor's degree during the breakfast time period is filtered out, totaling 136,221 records. An example of the dining log dataset result during the breakfast time period is shown in Table 4.

[0062] Table 4 Example of results of students’ dining log dataset during breakfast time

[0063] studentcode date consumption_time codename 14059674 2014-09-01 05:46 First Canteen 91078366 2014-09-15 08:25 The third canteen 25056141 2014-11-11 07:28 Second Canteen

[0064] Step 3: Set spatiotemporal co-occurrence constraints and, based on these constraints, obtain a "card swiping co-occurrence record dataset" from the dining log dataset obtained in step 2. The specific method is as follows:

[0065] Step 3.1: The spatiotemporal co-occurrence constraint for “simultaneous dining consumption events” between different students includes two parts: (1) the time difference between card swiping is within the set threshold; (2) the card swiping location is the same; that is, if two students’ dining consumption events occur at the same location during the same period and the time difference between them is within the set threshold, then the two students are considered to be “likely dining together”;

[0066] In this example, we use the "dining log dataset of undergraduate students enrolled in 2013 during the breakfast period" obtained in step 2 as an example. We set a spatiotemporal co-occurrence constraint for "simultaneous dining consumption events" between different students, and set the card swiping time difference threshold to 5 minutes. We also use the card swiping log data from the first cafeteria as an example to implement the constraint on the same location.

[0067] Step 3.2: Based on the spatiotemporal co-occurrence constraints set in step 3.1, filter the "card swiping co-occurrence records" that meet the spatiotemporal co-occurrence constraints from the dining log dataset obtained in step 2 to form a "card swiping co-occurrence record dataset." The data content of each card swiping co-occurrence record is <student M, student N, card swiping co-occurrence date>;

[0068] In this example, taking the "dining log dataset of students with undergraduate degree and matriculation year of 2013 during breakfast time" obtained in step 2 as an example, we filter the card swiping co-occurrence record dataset based on the time difference threshold of 5 minutes set in step 3.1 and the condition that the first cafeteria is the same location, resulting in a total of 1,298,544 student pairs.

[0069] Step 4: Based on the "card swiping co-occurrence record dataset" obtained in step 3, obtain the "card swiping co-occurrence student pair dataset". The specific method is:

[0070] For each student pair, count the number of co-occurrence records of their card swiping to obtain the co-occurrence statistics of the student pair; for all student pairs that appear in the "card swiping co-occurrence record dataset", obtain the co-occurrence statistics of the student pair's card swiping to form the "card swiping co-occurrence student pair dataset";

[0071] In this embodiment, taking the "card swiping co-occurrence record dataset" obtained in step 3 as an example, the number of card swiping co-occurrence records is counted to obtain a "card swiping co-occurrence student pair dataset". An example of the "card swiping co-occurrence student pair dataset" is shown in Table 5.

[0072] Table 5 Examples of card swipe co-occurrence student pair dataset

[0073]

[0074] Step 5: Based on the card swiping co-occurrence student pair dataset obtained in step 4, obtain the "high-frequency card swiping co-occurrence student pair dataset". The specific method is as follows:

[0075] Step 5.1: Count the "number of co-occurrences of card swiping" in the dataset of card swiping co-occurrence student pairs. According to the distribution characteristics of the number of co-occurrences of card swiping, set the "screening threshold for high-frequency card swiping co-occurrence student pairs"; the larger the threshold, the fewer high-frequency card swiping co-occurrence student pairs will be screened out;

[0076] In this embodiment, the card swiping co-occurrence student pair dataset obtained in step 4 is used as an example to count the distribution of different card swiping co-occurrence times. The statistical results are shown in Table 6.

[0077] Table 6 Card swiping co-occurrence statistics results

[0078] Card swipe co-occurrence times Number of occurrences of students 0-5 times 1144650 5-10 times 140614 10-15 times 10618 15-20 times 2397 20-25 times 205 25-30 times 51 30-35 times 7 35-40 times 2

[0079] Step 5.2: Filter the card swiping co-occurrence student pair dataset based on the set "Filtering threshold for high-frequency card swiping co-occurrence student pairs" and extract data with "card swiping co-occurrence times ≥ the filtering threshold for high-frequency card swiping co-occurrence student pairs" to obtain the high-frequency card swiping co-occurrence student pair dataset;

[0080] In this embodiment, the card swiping co-occurrence student pair dataset obtained in step 4 is taken as an example; the frequency of occurrence of each card swiping co-occurrence number in Table 8 is used to set the screening threshold of high-frequency card swiping co-occurrence student pairs to 15 times, and then a second screening is performed based on this threshold, ultimately obtaining a total of 379 high-frequency card swiping co-occurrence student pairs; an example of the final high-frequency card swiping co-occurrence student pair set is shown in Table 7;

[0081] Table 7 Examples of sets of high-frequency card swiping co-occurring student pairs

[0082]

[0083]

[0084] Step 6: Based on the high-frequency card swiping co-occurrence student pair dataset obtained in step 5, obtain the "high-frequency card swiping co-occurrence student group dataset". The specific method is as follows:

[0085] Step 6.1: In the dataset of high-frequency card swiping co-occurring student pairs, if the same student appears in different student pairs, the students in these pairs may form a "student group that may dine together"; select student pairs that may form a student group based on the student's unique identifier;

[0086] Step 6.2: Based on the set of student pairs that may constitute a student group, merge them according to the "mutual connection relationship of co-occurring student pairs" to obtain the "high-frequency card swiping co-occurring student group dataset";

[0087] In this embodiment, the high-frequency card swiping co-occurrence student pair dataset obtained in step 5 is used as an example to form a high-frequency card swiping co-occurrence student group dataset. Since the records in the high-frequency card swiping co-occurrence student pair dataset obtained in step 5 are all paired, but considering the daily campus life patterns and the social scope of students, there may be high-frequency card swiping co-occurrence student groups of three or more people. Therefore, the high-frequency card swiping co-occurrence student pairs obtained in step 5 are merged using the above idea, resulting in a total of 353 high-frequency card swiping co-occurrence student groups. An example of the high-frequency card swiping co-occurrence student group dataset is shown in Table 8.

[0088] Table 8 Examples of the high-frequency card swiping co-occurrence student group dataset

[0089]

[0090] Step 7: For the high-frequency card swiping co-occurrence student group dataset obtained in step 6, select a specific student group for visualization and analyze the dynamic changes in peer relationships among multiple students in the student group. The specific method is as follows:

[0091] Draw a line graph of the spending time of each student in the student group, using different line styles and colors to represent different students. Based on the time and space constraints, determine the peer relationships between them, and use different colors and bold marks to indicate the changes in these relationships. Taking a group of three as an example, if all three are peers on a certain day, use a single color and bold the lines. If only two of them are peers on a certain day, use the line color of any one of the students and bold it, thus intuitively showing the dynamic changes in peer relationships.

[0092] In this embodiment, the high-frequency card swiping co-occurrence student group in step five is taken as an example for visualization to show the peer group relationship of these students and the dynamic changes in peer relationships; the student with student number 74050027 is named student A, the student with student number 47062110 is named student B, and the student with student number 51061275 is named student C. From the visualization results, it can be seen that the dotted line is the daily consumption time of number A, and the other two solid lines are the daily consumption time of number B and number C respectively. When the student number A co-occurs with another classmate in time and space, the dotted line is bolded with the color of the classmate; from the effect of bolding with different colors, it can be intuitively felt that the dynamic changes in the spatiotemporal co-occurrence between the peers of student A during this period are relatively frequent, but the peer relationship is relatively stable, and there is no situation where the peer relationship disappears for a long time;

[0093] At this point, the student peer relationship discovery method based on campus card swiping log is completed.

Claims

1. A method for discovering student peer relationships based on campus card swiping logs, characterized in that: The following steps are involved: Step 1: Preprocess the original campus card swiping log dataset and uniquely identify students and locations. The specific method is as follows: The dataset used is campus card swiping log data. The dataset must contain at least the following information: the student's unique identifier, the merchant's unique identifier, and the unique identifier of the consumption time. Step 1.1: Perform data cleaning, that is, process any missing values ​​in the data. If any missing values ​​occur, delete the row record directly to avoid affecting the accuracy of the analysis. Step 1.2: Uniquely identify students in the dining consumption card swiping log dataset. Students are uniquely identified based on their student ID number. Step 1.3: Uniquely identify the consumption locations in the dining card consumption log dataset. Merchants merge merchants with the same consumption location based on the merchant's consumption location and uniquely identify the consumption location. Step 2: Based on the preprocessed campus card swiping log dataset, merge the card swiping records of the same day and time period to obtain the "dining log dataset". The specific method is as follows: Step 2.1: Based on the consumption type of the card swipe records, exclude "non-dining card swipe records" to improve the validity of the analysis results. The filtered card swipe logs are named "dining consumption card swipe log data set"; Step 2.2: Uniquely identify the consumption time in the dining card swipe log data set, and collect statistics on the time distribution of the card swipe records throughout the day. Based on the statistical results of the time distribution of the card swipe records, divide the time periods into breakfast, lunch, dinner, and supper; Step 2.3: For each student's card swipe records in each time period of each day, the earliest card swipe time among multiple card swipe records in that time period is used as the "student's dining time in that time period on that day", and a unique identifier is assigned to the dining time; After the above steps, the "dining log data set" is obtained. The content of each data in the dining log data set is shown in Table 1; Table 1 Description of the data content of the dining log dataset Step 3: Set spatiotemporal co-occurrence constraints and, based on these constraints, obtain a "card swiping co-occurrence record dataset" from the dining log dataset obtained in step 2. The specific method is as follows: Step 3.1: The spatiotemporal co-occurrence constraint for "simultaneous dining consumption events" between different students includes two parts: (1) the time difference between card swiping is within the set threshold; (2) the card swiping location is the same; that is, if two students' dining consumption events occur at the same location during the same period and the time difference between them is within the set threshold, then the two students are considered to be "likely dining together"; Students who meet the spatiotemporal co-occurrence constraints are the candidate group for "possible dining together"; Step 3.2: Based on the spatiotemporal co-occurrence constraints set in step 3.1, filter the "card swipe co-occurrence records" that meet the spatiotemporal co-occurrence constraints from the dining log dataset obtained in step 2 to form a "card swipe co-occurrence record dataset." The data content of each card swipe co-occurrence record is <student M, student N, card swipe co-occurrence date>; Step 4: Based on the "card swiping co-occurrence record dataset" obtained in step 3, obtain the "card swiping co-occurrence student pair dataset". The specific method is: For each student pair, the number of co-occurrence records of their card swiping is counted to obtain the co-occurrence statistics of the student pair; taking student M and student N as an example, the data content of the co-occurrence statistics of their card swiping is shown in Table 2; Table 2 Explanation of the statistical results of the co-occurrence of card swiping in student pairs For all student pairs that appear in the "Card Swipe Co-occurrence Record Dataset", obtain the card swipe co-occurrence statistics for each student pair to form the "Card Swipe Co-occurrence Student Pair Dataset"; Step 5: Based on the card swiping co-occurrence student pair dataset obtained in step 4, obtain the "high-frequency card swiping co-occurrence student pair dataset". The specific method is as follows: Step 5.1: Count the "number of co-occurrences of card swiping" in the card swiping co-occurrence student pairs dataset. Based on the distribution characteristics of the co-occurrences of card swiping, set a "screening threshold for high-frequency co-occurrence student pairs." The larger the threshold, the fewer high-frequency co-occurrence student pairs will be screened out. Step 5.2: Filter the card swiping co-occurrence student pair dataset based on the set "Filtering threshold for high-frequency card swiping co-occurrence student pairs" and extract data with "card swiping co-occurrence times ≥ filtering threshold for high-frequency card swiping co-occurrence student pairs" to obtain the high-frequency card swiping co-occurrence student pair dataset; Step 6: Based on the high-frequency card swiping co-occurrence student pair dataset obtained in step 5, obtain the "high-frequency card swiping co-occurrence student group dataset". The specific method is as follows: Step 6.1: In the dataset of high-frequency card swiping co-occurring student pairs, if the same student appears in different student pairs, the students in these pairs may form a "student group that may dine together"; select student pairs that may form a student group based on the student's unique identifier; Step 6.2: Based on the set of student pairs that may constitute a student group, merge them according to the "mutual connection relationship of co-occurring student pairs" to obtain the "high-frequency card swiping co-occurring student group dataset"; Step 7: For the high-frequency card swiping co-occurrence student group dataset obtained in step 6, select a specific student group for visualization and analyze the dynamic changes in peer relationships among multiple students in the student group. The specific method is as follows: Draw a line graph of the spending time of each student in the student group, using different line styles and colors to represent different students. Based on the time and space constraints, determine the peer relationships between them, and use different colors and bold marks to indicate the changes in these relationships. Taking a group of three as an example, if all three are peers on a certain day, use a single color and bold the lines. If only two of them are peers on a certain day, use the line color of any one of the students and bold it, thus intuitively showing the dynamic changes in peer relationships. At this point, the student peer discovery method based on campus card swiping logs has been completed. Through this method, a student peer relationship discovery method based on campus card swiping logs can be realized. This is a new method different from the traditional method through teacher observation or questionnaires. It discovers the peer relationship between students based on the spatial and temporal synchronization relationship of card swiping data, and realizes the tracking and analysis of the dynamic changes of peer relationships over time, providing path support for empowering education management level based on big data.