Car compartment crowdedness degree determination method, electronic device, and storage medium
Patent Information
- Application Number
- CN202211528585.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-30
- Publication Date
- 2026-09-18
- Estimated Expiration
- 2042-11-30
AI Technical Summary
乘客通常需要根据自己的乘车经验来选择某节车厢排队等候,经常出现因乘客排队等待的车厢的拥挤程度过高而导致乘客搭乘失败的情况,此时乘客需要耗费时间等待下一班交通工具
[0014] Compared to existing technologies, the method for determining the congestion level of a train carriage provided in this application determines the remaining carrying space of the carriage based on an internal top-view image of the carriage, determines the recommended remaining carrying capacity based on the remaining carrying space, the number of passengers already carried in the carriage, and the maximum carrying capacity of the carriage, and determines the congestion level of the carriage. This method can determine the congestion level of each carriage of a transportation vehicle, thereby recommending carriages with lower congestion levels to passengers to save their waiting time, thus avoiding safety problems caused by excessive passenger concentration and effectively achieving passenger flow separation.
Smart Images

Figure CN118172717B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of public transportation technology, and in particular to a method for determining the degree of crowding in a vehicle, an electronic device, and a storage medium. Background Technology
[0002] When passengers take public transportation (such as the subway), they usually cannot know in advance how crowded each carriage of the arriving train will be. Passengers typically need to choose a carriage to queue in based on their own experience, and often, passengers fail to board because the carriage they are waiting in is too crowded, thus having to wait for the next train. This way of traveling is too random, thus affecting travel efficiency. Summary of the Invention
[0003] In view of the above, it is necessary to provide a method, electronic device and storage medium for determining the degree of congestion in a train carriage, which can determine the degree of congestion in each carriage of a transportation vehicle, thereby recommending less crowded carriages to passengers to save passengers' waiting time and improve travel efficiency.
[0004] The method for determining the degree of crowding in the carriage includes: Image recognition is performed on the top-view image of the interior of the carriage, and the remaining carrying space inside the carriage is determined based on the image recognition results; The predicted remaining passenger capacity of the carriage is determined based on the remaining carrying capacity. Based on the number of passengers in the carriage, the predicted remaining capacity, and the maximum capacity of the carriage, the recommended remaining capacity of the carriage is determined. The level of crowding in the carriage is determined based on the recommended remaining passenger capacity and the maximum passenger capacity.
[0005] Optionally, the step of performing image recognition on the top-down view of the carriage interior, and determining the remaining carrying space within the carriage based on the image recognition result, includes: The area where the target object is located in the internal top view is identified using a preset image recognition algorithm, and the area where the target object is located is taken as the occupied area. The occupied area is updated according to preset rules to obtain the unoccupied area outside the occupied area; The unoccupied area is divided into stable unoccupied areas and unstable unoccupied areas; The remaining carrying space is determined based on the stable unoccupied area and the unstable unoccupied area.
[0006] Optionally, updating the occupied area according to a preset rule to obtain the unoccupied area outside the occupied area includes: Update the carriage wall panels in the internal top view image to the occupied areas; Determine the distance between the carriage wall panel and any other occupied area. If the distance is less than a preset distance threshold, update the area between the occupied area corresponding to the distance and the carriage wall panel to an occupied area. All areas outside of the occupied areas are considered as the unoccupied areas.
[0007] Optionally, dividing the unoccupied area into stable unoccupied areas and unstable unoccupied areas includes: The unoccupied area surrounded by the occupied area is identified as the surrounding area, and the surrounding area is regarded as the unstable unoccupied area; The unoccupied areas other than the unstable unoccupied areas are defined as the stable unoccupied areas.
[0008] Optionally, determining the remaining carrying space based on the stable unoccupied area and the unstable unoccupied area includes: Determine the conversion rate from the unstable unoccupied region to the stable unoccupied region; The remaining carrying space is calculated based on the area of the stable unoccupied area, the area of the unstable unoccupied area, and the conversion rate.
[0009] Optionally, determining the predicted remaining passenger capacity of the carriage based on the remaining carrying space includes: making the predicted remaining passenger capacity proportional to the remaining carrying space.
[0010] Optionally, the method further includes: The system detects the number of passengers boarding and alighting in each carriage at each stop, and determines the total number of passengers in the carriage based on the number of passengers boarding and alighting.
[0011] Optionally, the method further includes: Display the recommended remaining passenger capacity of the carriage to waiting passengers; According to the numerical range to which the level of congestion belongs, different colored indicator lights are used to display the level of congestion to the waiting passengers.
[0012] The computer-readable storage medium stores at least one instruction, which, when executed by a processor, implements the method for determining the degree of congestion in a train carriage.
[0013] The electronic device includes a memory and at least one processor. The memory stores at least one instruction, which, when executed by the at least one processor, implements the method for determining the degree of crowding in the carriage.
[0014] Compared to existing technologies, the method for determining the congestion level of a train carriage provided in this application determines the remaining carrying space of the carriage based on an internal top-view image of the carriage, determines the recommended remaining carrying capacity based on the remaining carrying space, the number of passengers already carried in the carriage, and the maximum carrying capacity of the carriage, and determines the congestion level of the carriage. This method can determine the congestion level of each carriage of a transportation vehicle, thereby recommending carriages with lower congestion levels to passengers to save their waiting time, thus avoiding safety problems caused by excessive passenger concentration and effectively achieving passenger flow separation. Attached Figure Description
[0015] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0016] Figure 1 This is a flowchart of a method for determining the degree of crowding in a train carriage, provided in an embodiment of this application.
[0017] Figure 2 This is a flowchart of determining the remaining carrying space inside a carriage, provided in an embodiment of this application.
[0018] Figure 3 This is an example diagram of the occupied area corresponding to the target object provided in the embodiments of this application.
[0019] Figure 4 This is a flowchart for determining unoccupied areas provided in an embodiment of this application.
[0020] Figure 5 This is a first example diagram of updating the occupied area provided in the embodiments of this application.
[0021] Figure 6 This is an example diagram showing the distance between the carriage wall panel and the occupied area provided in the embodiments of this application.
[0022] Figure 7 This is a second example diagram of the updated occupied area provided in the embodiments of this application.
[0023] Figure 8 This is an example diagram of an unstable unoccupied area provided in the embodiments of this application.
[0024] Figure 9 This is an architectural diagram of the electronic device provided in the embodiments of this application.
[0025] The following detailed description, in conjunction with the accompanying drawings, will further illustrate this application. Detailed Implementation
[0026] To better understand the above-mentioned objectives, features, and advantages of this application, the application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other.
[0027] Numerous specific details are set forth in the following description to provide a thorough understanding of this application. The described embodiments are merely some, not all, of the embodiments described herein. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0028] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application.
[0029] In one embodiment, when passengers take public transportation (such as a subway), they typically cannot know in advance how crowded each car of the arriving vehicle will be. Passengers usually need to choose a car to queue in based on their own travel experience, and often passengers fail to board because the cars they are queuing in are too crowded, in which case they have to spend time waiting for the next vehicle.
[0030] To address the aforementioned problems, this application provides a method for determining the crowding level of a train carriage. The method determines the remaining carrying capacity of the carriage based on an internal top-view image, then determines a recommended remaining carrying capacity based on the remaining carrying capacity, the number of passengers already in the carriage, and the carriage's maximum capacity, thus determining the level of crowding in the carriage. This method can save passengers' waiting time by determining the crowding level of each carriage, effectively improving travel efficiency and reducing safety hazards caused by overcrowding.
[0031] See Figure 1 The diagram shown is a flowchart of a method for determining the degree of crowding in a train carriage, provided in a preferred embodiment of this application.
[0032] In this embodiment, the method for determining the degree of crowding in the carriage can be applied to electronic devices (e.g., Figure 9The electronic device 3 shown can be an on-board device installed in a vehicle. For vehicles that need to determine the degree of vehicle congestion, the function of determining the degree of vehicle congestion provided by the method of this application embodiment can be directly integrated into the electronic device installed in each car of the vehicle, or it can be run in the form of a software development kit (SDK) on the electronic device installed in the vehicle.
[0033] like Figure 1 As shown, the method for determining the degree of crowding in the carriage specifically includes the following steps. Depending on different needs, the order of the steps in this flowchart can be changed, and some steps can be omitted.
[0034] Step S1: Perform image recognition on the top-view image of the interior of the carriage, and determine the remaining carrying space inside the carriage based on the image recognition results.
[0035] In one embodiment, a means of transportation (e.g., a subway) includes multiple carriages, each equipped with at least one camera device (e.g., a wide-angle camera) for acquiring an interior top-down view of the carriage. For example, at least one camera device can be mounted on the roof of the carriage to capture an interior top-down view.
[0036] In other embodiments, the camera device may further include a depth camera device, and the interior top view image may include a depth image with depth values captured by the depth camera device. Specifically, the depth image uses the depth values of each point in the carriage as pixel values.
[0037] In one embodiment, such as Figure 2 The diagram shown is a flowchart for determining the remaining carrying space inside the carriage according to an embodiment of this application, and specifically includes the following steps: Step S11: Use a preset image recognition algorithm to identify the area where the target object is located in the internal top view, and take the area where the target object is located as the occupied area.
[0038] In one embodiment, the image recognition algorithm includes object detection algorithms, including but not limited to R-CNN (Region with Convolutional Neural Network features), YOLO (You Only Look Once), and SSD (Single Short multibox Detector).
[0039] In one embodiment, the target object includes, but is not limited to, people and luggage (e.g., suitcases). Furthermore, considering that passengers can carry smaller pieces of luggage, while larger pieces must be placed on the carriage floor, thus occupying space, an area threshold (e.g., 0.5 square meters) can be preset, designating the area containing luggage larger than the threshold as the area containing the target object. Alternatively, the area threshold can be set based on the ratio of the internal top-view image to the actual area of the carriage, for example, 100 pixels.
[0040] In other embodiments, in addition to the image recognition algorithm, the depth image described in step S1 can be used to further identify and filter the area where the target object is located. For example, a depth threshold (e.g., 1.5 meters) can be preset, and areas smaller than the depth threshold can be removed from the area where the target object is located. The depth threshold can also be set based on the actual height of the carriage.
[0041] After detecting the target object, the image recognition algorithm automatically selects the area where the target object is located to obtain the occupied area. For example, it uses a rectangle to select the area where the target object is located, and the area within the rectangle is taken as the occupied area. Figure 3 The image shown is an example of the occupied area corresponding to the target object provided in this application embodiment. The entire image represents the internal top view image, the outer dashed rectangle represents the carriage wall panel, the black line in the dashed rectangle represents the carriage door, and the black-filled square area represents the occupied area obtained after selecting the target object.
[0042] Step S12: Update the occupied area according to the preset rules to obtain the unoccupied area outside the occupied area.
[0043] In one embodiment, such as Figure 4 The diagram shown is a flowchart for determining unoccupied areas according to an embodiment of this application, specifically including the following steps: Step S121: Update the carriage wall panels in the internal top view image to occupied areas.
[0044] In one embodiment, the carriage wall panel is located at the edge of the carriage and belongs to the enclosed and fixed area around it. Therefore, the carriage wall panel can be updated to an occupied area, which is equivalent to an area occupied by passengers.
[0045] In addition, the area around the carriage doors is an open area, and passengers need to enter and exit through the carriage doors. When new passengers enter through the carriage doors, the passengers who were originally at the carriage doors will generally be pushed and automatically move into the carriage away from the carriage doors. Therefore, the area around the carriage doors can be considered an unoccupied area.
[0046] For example Figure 5 The diagram shown is a first example of updating the occupied area according to an embodiment of this application. Figure 5 exist Figure 3 Based on this, the surrounding carriage walls are updated to indicate occupied areas with solid black lines, and the blank gaps in the solid black lines of the carriage walls indicate unoccupied areas where the carriage doors are located.
[0047] In other embodiments, other fixed facilities in the carriage, such as handrails, seats, etc., can also be considered as occupied areas.
[0048] Step S122: Determine the distance between the carriage wall panel and any other occupied area. If the distance is less than a preset distance threshold, update the area between the occupied area corresponding to the distance and the carriage wall panel to an occupied area.
[0049] In one embodiment, determining the distance between the carriage wall panel and any other occupied area includes: using the interior top-view image (e.g. Figure 5 Establish a rectangular coordinate system XOY with the lower left corner of the coordinate system as the origin O (e.g., Figure 6 Using the long side of the internal top view image as the horizontal axis X of the rectangular coordinate system and the short side of the internal top view image as the vertical axis Y of the rectangular coordinate system, and using the size of each pixel as the unit length, the distance between the carriage wall panel and any other occupied area is determined based on the rectangular coordinate system.
[0050] In one embodiment, such as Figure 6 The diagram shown is an example of the distance between the carriage wall panel and the occupied area provided in an embodiment of this application. The diagram includes an interior top view containing the occupied area (e.g., a top view image). Figure 5 The rectangular coordinate system XOY is established based on ) as follows Figure 6 As shown, the distances between the carriage wall panel and any other occupied area are, for example, D1, D2, D3, and D4.
[0051] In one embodiment, when a new passenger enters the carriage, the passenger at the innermost part of the carriage, closest to the carriage wall, generally will not move. Therefore, if the distance is less than a preset distance threshold, it means that the passenger in any occupied area corresponding to that distance is very close to the carriage wall, and the area between any occupied area corresponding to that distance and the carriage wall can be updated to an occupied area.
[0052] In one embodiment, the distance threshold can be set based on the size of the occupied area corresponding to the human body, and can be set to one-third or one-half of the diameter (or length, width) of the occupied area corresponding to the human body. For example, Figure 5If the average side length of the area occupied by the square is 30 pixels, then the distance threshold can be set to 30 × 1 / 3, that is, the distance threshold can be set to 10 pixels.
[0053] In one embodiment, such as Figure 7 The image shown is a second example diagram of the updated occupied area provided in an embodiment of this application. Wherein, in Figure 5 Based on this, the updated established occupied areas are as follows: Figure 7 As shown in the top left and top right corners.
[0054] Step S123: All areas outside of the occupied areas are designated as the unoccupied areas.
[0055] In one embodiment, such as Figure 7 As shown, the blank areas outside the black occupied areas are the unoccupied areas.
[0056] Step S13: Divide the unoccupied area into stable unoccupied areas and unstable unoccupied areas.
[0057] In one embodiment, dividing the unoccupied area into stable unoccupied areas and unstable unoccupied areas includes: determining an unoccupied area surrounded by the occupied area as an enclosing area, and designating the enclosing area as the unstable unoccupied area; and designating the unoccupied area other than the unstable unoccupied area as the stable unoccupied area.
[0058] In one embodiment, determining the unoccupied area surrounded by the occupied area as the enclosing area includes: using an image recognition algorithm (e.g., a contour recognition algorithm) to determine the closed contour of the unoccupied area composed of the occupied area, and taking the unoccupied area within the closed contour as the enclosing area.
[0059] In one embodiment, when there is an enclosed area formed by multiple passengers within the carriage, and a new passenger enters the carriage, the following situation occurs: Scenario 1: Passengers give way to newly entering passengers, causing existing passengers in the carriage to move and squeeze into the enclosed area, or newly entering passengers enter the enclosed area. In this case, the enclosed area can be considered an unoccupied area. Scenario 2: If the area enclosed by multiple passengers is small (for example, smaller than the area threshold mentioned in step S11), the passengers may not move or may move together, making it impossible for the enclosed area to accommodate new passengers. In this case, the enclosed area can be regarded as an occupied area.
[0060] Based on the above, the enclosed area is considered as the unstable unoccupied area. For example... Figure 8The diagram shown is an example of an unstable unoccupied area provided in an embodiment of this application. Wherein, Figure 8 The gray area in the upper right corner represents an unstable, unoccupied area.
[0061] Furthermore, since the unoccupied areas outside the enclosed area are not enclosed, existing and newly arriving passengers can move freely and automatically within these unoccupied areas. Therefore, the areas within the unoccupied areas other than the unstable unoccupied areas are considered as the stable unoccupied areas, for example, Figure 8 The blank area shown.
[0062] Step S14: Determine the remaining carrying space based on the stable unoccupied area and the unstable unoccupied area.
[0063] In one embodiment, determining the remaining carrying space based on the stable unoccupied area and the unstable unoccupied area includes: determining the conversion rate of the unstable unoccupied area to the stable unoccupied area; and calculating the remaining carrying space based on the area of the stable unoccupied area, the area of the unstable unoccupied area, and the conversion rate.
[0064] In one embodiment, referring to the description in step S13, due to the subjective will of the passengers already in the carriage, it cannot be determined whether all the unstable unoccupied areas can be converted into stable unoccupied areas. The conversion rate from unstable unoccupied areas to stable unoccupied areas can be determined based on historical data.
[0065] Specifically, the historical data is prior data. For example, the prior data indicates that the conversion rate varies depending on the area of the historically unstable unoccupied region, and the size of the historically unstable unoccupied region is directly proportional to the conversion rate. For instance, when the area of the historically unstable unoccupied region is between 300 and 600 pixels, the conversion rate is 0.3; when the area of the historically unstable unoccupied region is between 600 and 900 pixels, the conversion rate is 0.5, and so on.
[0066] Therefore, referring to the method of establishing a Cartesian coordinate system in step S122, the area of each unstable unoccupied region and the area range to which each unstable unoccupied region belongs can be determined. Then, based on prior data, the conversion rate from the unstable unoccupied region to the stable unoccupied region can be determined. For example, if the area of unstable unoccupied region A is 800 pixels, and its area range is 600 to 900 pixels, then the conversion rate from unstable unoccupied region A to the stable unoccupied region is 0.5.
[0067] In one embodiment, calculating the remaining carrying capacity based on the area of the stable unoccupied area, the area of the unstable unoccupied area, and the conversion rate includes: setting the remaining carrying capacity = area of the stable unoccupied area + ∑ area of any unstable unoccupied area × conversion rate corresponding to any unstable unoccupied area. The area of the stable unoccupied area can be determined by referring to the method of establishing a Cartesian coordinate system in step S122.
[0068] For example, Figure 8 The stable unoccupied region (blank area) has an area of 14,600 pixels, while the only unstable unoccupied region A has an area of 800 pixels and a corresponding conversion rate of 0.5. Figure 8 The remaining carrying space mentioned above = area of the stable unoccupied area + area of the unstable unoccupied area A × conversion rate corresponding to the unstable unoccupied area A = 14600 pixels + 800 pixels × 0.5 = 15000 pixels.
[0069] Step S2: Determine the predicted remaining number of passengers that the carriage can carry based on the remaining carrying space.
[0070] In one embodiment, determining the predicted remaining passenger capacity of the carriage based on the remaining carrying space includes: making the predicted remaining passenger capacity proportional to the remaining carrying space.
[0071] Specifically, in step S1, the area S of the remaining carrying space (e.g., 15,000 pixels) has been determined, and the number of people p (e.g., 5) that can be accommodated per square meter can be determined. Then, the number N (e.g., 1,500 pixels) corresponding to one square meter in the internal top view image is determined. Therefore, N pixels in the internal top view image can accommodate p people. Then, the remaining carrying capacity Pimage = (S × p) / N (e.g., (15,000 × 5) / 1,500 = 50).
[0072] In other embodiments, in addition to the method of representing distance and area with the number of pixels described above, the ratio of the length of the internal top view image to the actual length of the carriage and the ratio of the width of the internal top view image to the actual width of the carriage can be obtained first, so as to obtain the actual distance corresponding to any distance in the internal top view image and the actual area corresponding to any area in the internal top view image according to the ratio.
[0073] Step S3: Based on the number of passengers in the carriage, the predicted remaining passenger capacity, and the maximum passenger capacity of the carriage, determine the recommended remaining passenger capacity of the carriage.
[0074] In one embodiment, the predicted remaining capacity obtained in step S2 is a value inferred from the internal top-view image. Because the internal top-view image undergoes multiple processing steps as described in step S1, the predicted remaining capacity contains errors and cannot be used as the final recommended remaining capacity. Therefore, step S3 is needed to further process the predicted remaining capacity to obtain the final recommended remaining capacity. For example, the final recommended remaining capacity can be obtained through a preset percentage, such as 50%, as illustrated in the example below.
[0075] In one embodiment, determining the recommended remaining capacity of a carriage based on the number of passengers in the carriage, the predicted remaining capacity, and the maximum capacity of the carriage includes: setting the recommended remaining capacity = (maximum capacity of the carriage - number of passengers in the carriage + predicted remaining capacity) / 2.
[0076] In one embodiment, the method further includes: detecting the number of passengers boarding and alighting in the carriage at each station, and determining the number of passengers in the carriage based on the number of passengers boarding and alighting.
[0077] In one embodiment, each carriage is also equipped with an object movement sensor or a human body sensor for detecting human bodies. Specifically, the human body sensor may include an infrared sensor, which may be installed at the door position of the carriage (e.g., around the four sides of the door) to detect the number of passengers boarding and alighting at each stop, thereby determining the number of passengers in the carriage based on the number of passengers boarding and alighting.
[0078] Specifically, starting from the originating station of the vehicle, the number of passengers boarding and alighting in the carriage at each station is detected. At each subsequent station, the number of passengers boarding is added and the number of passengers alighting is subtracted to obtain the number of passengers in the carriage (e.g., 40).
[0079] In one embodiment, the maximum passenger capacity of the carriage is known data provided by the carriage manufacturer, for example, the maximum passenger capacity is 101.
[0080] In one embodiment, the maximum capacity of the carriage minus the number of passengers in the carriage is the ideal remaining capacity of the carriage. However, referring to the step of updating the occupied area in step S1, due to various reasons, the carriage cannot continue to accommodate the ideal remaining capacity. In other embodiments, besides the method described above of setting the recommended remaining capacity as the average of the predicted remaining capacity and the ideal remaining capacity, the recommended remaining capacity can also be directly set as a value between the predicted remaining capacity and the ideal remaining capacity. This allows the carriage to carry as many people as possible while ensuring that the carriage is not overloaded.
[0081] In one embodiment, the calculated recommended remaining passenger capacity may not be an integer. In this case, it can be rounded down to obtain an integer value. For example, the recommended remaining passenger capacity = (maximum capacity of the carriage - number of passengers in the carriage + predicted remaining passenger capacity) / 2 = (101 - 40 + 50) / 2 = 55.5. Rounding down 55.5 gives a recommended remaining passenger capacity of 55. In other embodiments, it can also be rounded up, giving a recommended remaining passenger capacity of 56.
[0082] Step S4: Determine the crowding level of the carriage based on the recommended remaining passenger capacity and the maximum passenger capacity.
[0083] In one embodiment, determining the crowding level of the carriage based on the recommended remaining passenger capacity and the maximum passenger capacity includes setting the crowding level as 1 - the recommended remaining passenger capacity / the maximum passenger capacity.
[0084] In one embodiment, the crowding level refers to the degree of overcrowding in the carriage. A higher crowding level indicates more passengers in the carriage, fewer new passengers can be accommodated, and it is less recommended for new passengers to board. For example, the crowding level = 55 / 110 = 0.5.
[0085] In one embodiment, the method further includes: displaying the recommended remaining passenger capacity of the carriage to waiting passengers; and displaying the degree of crowding represented by a corresponding numerical range using indicator lights of different colors according to the numerical range to which the crowding level belongs.
[0086] In one embodiment, the recommended remaining capacity and crowding level of each carriage are transmitted via a network to a terminal platform associated with the transportation vehicle, such as a mobile application or app, or a display device installed at the station. This allows waiting passengers to see the recommended remaining capacity and crowding level of each carriage before the vehicle arrives at the station, enabling them to know the occupancy status of each carriage and choose a less crowded carriage to queue for, thus avoiding missed journeys.
[0087] In one embodiment, each carriage may also be equipped with a display device, such as a monitor, for displaying the interior top-down view. Specifically, the display device may be installed outside the carriage door, allowing waiting passengers to determine the location of a target empty area within the carriage based on the interior top-down view.
[0088] In addition, the display device may also include indicator lights, using different colored indicator lights to display the degree of congestion to the waiting passengers using corresponding numerical ranges. For example, a red indicator light is used to indicate when the degree of congestion is in the range of 0.7 to 0.9; a green indicator light is used to indicate when the degree of congestion is in the range of 0.1 to 0.2.
[0089] In one embodiment, the method for determining the congestion level of a carriage provided in this application determines the remaining carrying space of the carriage based on an internal top-view image of the carriage, determines the recommended remaining carrying capacity based on the remaining carrying space, the number of passengers already carried in the carriage, and the maximum carrying capacity of the carriage, and determines the congestion level of the carriage. This method can determine the congestion level of each carriage of a transportation vehicle, thereby recommending carriages with lower congestion levels to passengers to save their waiting time.
[0090] The above Figure 1 This application details the method for determining the degree of crowdedness in train carriages. The following section combines this method with... Figure 9 The functional modules of the software system for implementing the method for determining the degree of crowdedness in a train carriage, as well as the hardware device architecture for implementing the method for determining the degree of crowdedness in a train carriage, are introduced.
[0091] It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.
[0092] See Figure 9 The diagram shown is a structural schematic of an electronic device provided in a preferred embodiment of this application.
[0093] In a preferred embodiment of this application, the electronic device 3 includes a memory 31 and at least one processor 32. Those skilled in the art should understand that... Figure 9The structure of the electronic device shown does not constitute a limitation of the embodiments of this application. It can be a bus structure or a star structure. The electronic device 3 may also include more or fewer other hardware or software than shown, or different component arrangements.
[0094] In some embodiments, the electronic device 3 includes a terminal capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, the hardware of which includes, but is not limited to, microprocessors, application-specific integrated circuits, programmable gate arrays, digital processors, and embedded devices.
[0095] It should be noted that the electronic device 3 is merely an example. Other existing or future electronic products that are suitable for this application should also be included within the scope of protection of this application and are incorporated herein by reference.
[0096] In some embodiments, the memory 31 is used to store program code and various data. For example, the memory 31 can be used to store a vehicle congestion determination system 30 installed in the electronic device 3, and to enable high-speed, automatic access to programs or data during the operation of the electronic device 3. The memory 31 includes read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, disk storage, magnetic tape storage, or any other computer-readable storage medium capable of carrying or storing data.
[0097] In some embodiments, the at least one processor 32 may be composed of integrated circuits, such as a single-packaged integrated circuit or multiple integrated circuits packaged with the same or different functions, including combinations of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips. The at least one processor 32 is the control unit of the electronic device 3, connecting various components of the entire electronic device 3 via various interfaces and lines. It executes programs or modules stored in the memory 31 and calls data stored in the memory 31 to perform various functions of the electronic device 3 and process data, such as executing... Figure 1 The function indicates the level of crowding in the carriages.
[0098] In some embodiments, the carriage crowding level determination system 30 operates within an electronic device 3. The carriage crowding level determination system 30 may include multiple functional modules composed of program code segments. The program code of each program segment in the carriage crowding level determination system 30 may be stored in the memory 31 of the electronic device 3 and executed by at least one processor 32 to achieve... Figure 1 The function indicates the level of crowding in the carriages.
[0099] In this embodiment, the carriage crowding level determination system 30 can be divided into multiple functional modules according to the functions it performs. A module, as referred to in this application, is a series of computer program segments that can be executed by at least one processor and perform a fixed function, and is stored in memory.
[0100] Although not shown, the electronic device 3 may also include a power supply (such as a battery) to power the various components. Preferably, the power supply can be logically connected to the at least one processor 32 through a power management device, thereby enabling functions such as charging, discharging, and power consumption management. The power supply may also include one or more DC or AC power supplies, recharging devices, power failure testing circuits, power converters or inverters, power status indicators, and other arbitrary components. The electronic device 3 may also include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.
[0101] It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.
[0102] The integrated unit implemented as a software functional module described above can be stored in a computer-readable storage medium. This software functional module, stored in a storage medium, includes several instructions to cause an electronic device (which may be a server, personal computer, etc.) or processor to execute portions of the methods described in the various embodiments of this application.
[0103] The memory 31 stores program code, and the at least one processor 32 can call the program code stored in the memory 31 to execute related functions. The program code stored in the memory 31 can be executed by the at least one processor 32 to realize the functions of each module to achieve the purpose of determining the degree of crowding in the carriage.
[0104] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and other division methods may be used in actual implementation.
[0105] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0106] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional modules.
[0107] It will be apparent to those skilled in the art that this application is not limited to the details of the exemplary embodiments described above, and that this application can be implemented in other specific forms without departing from the spirit or essential characteristics of this application. Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of this application is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be embraced within this application. No reference numerals in the claims should be construed as limiting the scope of the claims. Furthermore, it is clear that the word "comprising" does not exclude other elements or, and the singular does not exclude the plural. Multiple elements or devices recited in the apparatus claims may also be implemented by a single element or device in software or hardware. The terms "first," "second," etc., are used to indicate names and do not indicate any particular order.
[0108] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application and are not intended to limit it. Although this application has been described in detail with reference to the above preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of this application without departing from the spirit and scope of the technical solutions of this application.
Claims
1. A method for determining the degree of crowding in a train carriage, applied in electronic equipment, characterized in that, The method includes: Image recognition is performed on the interior top-view image of the carriage, and the remaining carrying space in the carriage is determined based on the image recognition results. This includes: using a preset image recognition algorithm to identify the area where a target object is located in the interior top-view, and designating the area where the target object is located as an occupied area; updating the carriage wall panels in the interior top-view image as occupied areas; determining the distance between the carriage wall panels and any other occupied area; if the distance is less than a preset distance threshold, updating the area between any occupied area corresponding to that distance and the carriage wall panel as an occupied area; designating all areas outside the occupied areas as unoccupied areas; determining unoccupied areas surrounded by the occupied areas as enclosed areas, and designating the enclosed areas as unstable unoccupied areas; designating areas within the unoccupied areas other than the unstable unoccupied areas as stable unoccupied areas; determining the conversion rate from the unstable unoccupied areas to the stable unoccupied areas; and calculating the remaining carrying space based on the area of the stable unoccupied areas, the area of the unstable unoccupied areas, and the conversion rate. The predicted remaining passenger capacity of the carriage is determined based on the remaining carrying capacity. Based on the number of passengers in the carriage, the predicted remaining capacity, and the maximum capacity of the carriage, the recommended remaining capacity of the carriage is determined. The level of crowding in the carriage is determined based on the recommended remaining passenger capacity and the maximum passenger capacity.
2. The method for determining the degree of crowdedness in a train carriage according to claim 1, characterized in that, The process of performing image recognition on the top-down view of the carriage interior, and determining the remaining carrying space within the carriage based on the image recognition results, includes: The occupied area is updated according to preset rules to obtain the unoccupied area outside the occupied area; The unoccupied area is divided into stable unoccupied areas and unstable unoccupied areas; The remaining carrying space is determined based on the stable unoccupied area and the unstable unoccupied area.
3. The method for determining the degree of crowdedness in a train carriage according to claim 1, characterized in that: The step of determining the predicted remaining passenger capacity of the carriage based on the remaining carrying space includes: making the predicted remaining passenger capacity proportional to the remaining carrying space.
4. The method for determining the degree of crowdedness in a train carriage according to claim 1, characterized in that, The method further includes: The system detects the number of passengers boarding and alighting in each carriage at each stop, and determines the total number of passengers in the carriage based on the number of passengers boarding and alighting.
5. The method for determining the degree of crowdedness in a train carriage according to claim 1, characterized in that, The method further includes: Display the recommended remaining passenger capacity of the carriage to waiting passengers; According to the numerical range to which the level of congestion belongs, different colored indicator lights are used to display the level of congestion to the waiting passengers.
6. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores at least one instruction, which, when executed by a processor, implements the method for determining the degree of crowdedness of a train carriage as described in any one of claims 1 to 5.
7. An electronic device, characterized in that, The electronic device includes a memory and at least one processor, wherein the memory stores at least one instruction, which, when executed by the at least one processor, implements the method for determining the degree of crowdedness of a train carriage as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Bus crowding degree determination method and device
CN107145819A
Subway train carriage passenger flow detection and prediction and platform waiting induction system
CN111259714A