[go: up one dir, main page]

CN112599223A - Compression method, device, equipment and storage medium for browser film reading data - Google Patents

Compression method, device, equipment and storage medium for browser film reading data Download PDF

Info

Publication number
CN112599223A
CN112599223A CN202011270114.XA CN202011270114A CN112599223A CN 112599223 A CN112599223 A CN 112599223A CN 202011270114 A CN202011270114 A CN 202011270114A CN 112599223 A CN112599223 A CN 112599223A
Authority
CN
China
Prior art keywords
file
data
compressed
target
dicom
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011270114.XA
Other languages
Chinese (zh)
Inventor
方伟
徐玲
吴桐
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanyang Clear Technology Co Ltd
Original Assignee
Nanyang Clear Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanyang Clear Technology Co Ltd filed Critical Nanyang Clear Technology Co Ltd
Priority to CN202011270114.XA priority Critical patent/CN112599223A/en
Publication of CN112599223A publication Critical patent/CN112599223A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H30/00ICT specially adapted for the handling or processing of medical images
    • G16H30/20ICT specially adapted for the handling or processing of medical images for handling medical images, e.g. DICOM, HL7 or PACS
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Radiology & Medical Imaging (AREA)
  • Epidemiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Nuclear Medicine, Radiotherapy & Molecular Imaging (AREA)
  • Primary Health Care (AREA)
  • Public Health (AREA)
  • Multimedia (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Measuring And Recording Apparatus For Diagnosis (AREA)

Abstract

本发明实施例公开了一种浏览器阅片数据的压缩方法、装置、设备及存储介质,其中,该方法包括:接收医学数字成像和通信DICOM源文件,根据所述DICOM源文件获取到对应的文本数据及图像数据,所述DICOM源文件为所述浏览器阅片数据;根据所述DICOM源文件、所述文本数据及图像数据提取压缩数据,得到目标文件;使用预设压缩算法压缩所述目标文件,获得目标压缩文件。通过对DICOM源文件、文本数据及图像数据提取压缩数据,使得该压缩数据相对于原文件进行了精简,且利用压缩算法对目标文件进行压缩,可以进一步的减少存储压缩得到的目标压缩文件所需要的存储长度,使得减少对磁盘空间的占用,降低企业成本。

Figure 202011270114

Embodiments of the present invention disclose a method, device, device and storage medium for compressing image reading data by a browser, wherein the method includes: receiving a DICOM source file for medical digital imaging and communication, and obtaining a corresponding DICOM source file according to the DICOM source file Text data and image data, the DICOM source file is the browser reading data; extract compressed data according to the DICOM source file, the text data and the image data, and obtain a target file; use a preset compression algorithm to compress the target file, get the target compressed file. By extracting compressed data from DICOM source files, text data and image data, the compressed data is simplified compared to the original file, and the target file is compressed by a compression algorithm, which can further reduce the need for storing the compressed target compressed file. The storage length is longer, which reduces the occupation of disk space and reduces the cost of enterprises.

Figure 202011270114

Description

Compression method, device, equipment and storage medium for browser film reading data
Technical Field
The invention relates to the technical field of image compression, in particular to a method, a device, equipment and a storage medium for compressing browser film reading data.
Background
Digital Imaging and Communications in Medicine (DICOM) is widely used in the fields of radiology, cardiovascular Imaging, and diagnostic radiology equipment such as X-ray, Computed Tomography (CT), nuclear magnetic resonance, ultrasound, etc.; medical images of patients are stored in a DICOM file format that contains information about the patient's name, sex, age, and other image-related information such as device information for capturing and generating the images, each image carrying a large amount of information and requiring high image quality.
When the DICOM source file is received by the browser, where the source file includes image information and patient information, i.e., patient images and corresponding text, converting the source file into three files includes: the xml file, that is, the read non-image data part is stored in a network transmission format in the xml format, the png file, that is, a specific image to be displayed and a thumbnail of a jpeg file image, and then the three files and the received DICOM source file are stored in a disk, so that a large amount of disk space is occupied, and the enterprise cost is increased.
Disclosure of Invention
The application provides a compression method and device for browser film reading data and a storage medium.
In a first aspect, a method for compressing browser interpretation data is provided, where the method is executed in a memory, and the method includes:
receiving a DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is the browser film reading data;
extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file;
and compressing the target file by using a preset compression algorithm to obtain a target compressed file.
In an alternative embodiment, the extracting compressed data according to the DICOM source file, the text data and the image data to obtain an object file includes:
analyzing the DICOM source file, the text data and the image data by using a preset protocol to obtain compressed data;
and performing data merging storage on the compressed data in a byte array mode to obtain the target file.
In an optional implementation, the acquiring corresponding text data and image data according to the DICOM source file includes:
intercepting images from the DICOM source file according to frames to obtain a plurality of images with corresponding frame numbers, and virtually printing the plurality of images in a preset typesetting format through a virtual printer to obtain a typesetting image containing the plurality of images;
and performing preset format conversion on the typeset image to obtain corresponding text data and image data in a preset format file.
In an optional implementation manner, the performing the preset format conversion on the layout image to obtain corresponding text data and image data in a preset format file includes:
converting the typesetting image into an XML format file to obtain the text data in the XML format file;
and the typesetting image is converted into a portable network picture png format file and a destructive image jpeg format file, and the png format file and the image data in the jpeg format are obtained.
In an optional embodiment, the compressing the target file by using a preset compression algorithm to obtain a target compressed file includes:
calculating the length of memory bytes occupied by the target file to obtain the length of bytes to be compressed;
and determining a compression parameter of a preset compression algorithm according to the length of the byte to be compressed, and compressing the target file by using the compression parameter to obtain the target compressed file.
In an optional implementation manner, the compressing the target file using a preset compression algorithm to obtain a target compressed file further includes:
if a storage request is received, storing the target compressed file to a disk;
and if a transmission request is received, the target compressed file is stored to a disk and then transmitted to a request sending client.
In an alternative embodiment, the receiving a DICOM source file for digital imaging and communications in medicine further comprises:
sending a source file acquisition request to an imaging device;
if a source file acquisition response is received, extracting the DICOM source file from the source file acquisition response;
and if receiving the delayed response of the source file, receiving the DICOM source file fed back by the imaging equipment after waiting for a preset delay time.
In a second aspect, a device for compressing and transmitting browser interpretation data is provided, which is characterized by comprising:
a receiving module: the system comprises a browser, a DICOM source file, a display and a display, wherein the browser is used for receiving a medical digital imaging and communication DICOM source file and acquiring corresponding text data and image data according to the DICOM source file, and the DICOM source file is the browser reading data;
an extraction module: the DICOM source file is used for extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file;
a compression module: and the target file is compressed by using a preset compression algorithm to obtain a target compressed file.
In a third aspect, there is provided an apparatus comprising a memory and a processor, the memory storing a computer program which, when executed by the processor, causes the processor to perform the steps of the first aspect and any possible implementation thereof.
In a fourth aspect, a computer-readable storage medium is provided, which is characterized by a computer program stored thereon, which, when executed by a processor, causes the processor to perform the steps of the first aspect and any of its possible implementations.
The embodiment of the invention has the following beneficial effects:
the method comprises the steps of receiving a DICOM source file for medical digital imaging and communication, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser reading data; extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file; and compressing the target file by using a preset compression algorithm to obtain a target compressed file. By extracting compressed data from the DICOM source file, the text data and the image data, the compressed data is simplified relative to the original file, and the target file is compressed by using a compression algorithm, so that the storage length required by storing the compressed target file can be further reduced, the occupation of the disk space is reduced, and the enterprise cost is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Wherein:
fig. 1 is a schematic flowchart of a method for compressing browser interpretation data according to an embodiment of the present invention;
fig. 2 is another schematic flowchart of a method for compressing browser interpretation data according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of another flowchart of a method for compressing browser interpretation data according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a compressing apparatus for browser interpretation data according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an apparatus according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without any inventive step, shall fall within the scope of the present invention.
As shown in fig. 1, which is a flowchart illustrating a method for compressing browser snippets according to an embodiment of the present invention, the method shown in fig. 1 is executed in a memory, and the method includes the following steps:
101. receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data;
it should be noted that Digital Imaging and Communications in Medicine (DICOM) is an international standard for medical images and related information (ISO 12052), and among tens of thousands of medical Imaging devices in use, DICOM is one of the most widely deployed medical information standards, defining a medical image format that can be used for data exchange with quality meeting clinical needs.
Medical images of all patients are stored in a DICOM file format, which contains Protected Health Information (PHI) about the patients, such as name, gender, age, and other image-related information, such as device information for capturing and generating images and some context-related information for medical treatment. The medical image facility generates a DICOM source file that the physician reads and diagnoses problems found in the image using a DICOM reader (computer software capable of displaying DICOM images).
It is understood that the act of a doctor using a DICOM reader (computer software capable of displaying DICOM images) to read and diagnose a problem found in an image is a browser reading act, and the image being diagnosed, i.e. the DICOM source file, is browser reading data.
It is understood that the browser reading action may further include the patient viewing the diagnosis result of the patient, including text and images, by using other intelligent devices, for example, through a personal computer, a mobile phone, etc., and may also include viewing the images during the image sharing diagnosis of the cross-regional medical consultation.
102. Extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file;
it should be noted that the compressed data refers to specific data related to the explicit diagnosis result in the text and image information in the dicom source file, for example, device information for capturing and generating an image contained in the dicom source file is information unrelated to the diagnosis result, and therefore, the compressed data needs to be further extracted from the text and image information in the dicom source file, so as to further reduce the compression range of the target file.
103. And compressing the target file by using a preset compression algorithm to obtain a target compressed file.
In the embodiment of the present invention, compressing the target file with the reduced compression range may further reduce the occupied space of the obtained target compressed file.
It will be appreciated that the pre-set compression algorithm may be a compression algorithm implemented based on LZ77 encoding theory.
According to the embodiment of the invention, a DICOM source file is received, and corresponding text data and image data are acquired according to the DICOM source file, wherein the DICOM source file is browser reading data; extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file; and compressing the target file by using a preset compression algorithm to obtain a target compressed file. By extracting compressed data from the DICOM source file, the text data and the image data, the compressed data is simplified relative to the original file, and the target file is compressed by using a compression algorithm, so that the storage length required by storing the compressed target file can be further reduced, the occupation of the disk space is reduced, and the enterprise cost is reduced.
To better understand the embodiment of the present invention, as shown in fig. 2, another schematic flow chart of a method for compressing browser browsing data according to the embodiment of the present invention is shown, where the method shown in fig. 2 specifically includes the following steps:
201. receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data;
the content related to step 201 included in the compression method for browser rendering data in the embodiment of the present invention shown in fig. 2 is similar to the content related to step 101 in the compression method for browser rendering data in the embodiment shown in fig. 1, and specifically, the content described in step 101 in fig. 1 may be referred to, and is not described herein again.
In an embodiment of the present invention, receiving a DICOM source file for digital imaging and communications in medicine further comprises:
sending a source file acquisition request to an imaging device;
if the source file acquisition response is received, extracting the DICOM source file from the source file acquisition response;
and if the source file delay response is received, receiving the DICOM source file fed back by the imaging equipment after waiting for a preset delay time.
In the embodiment of the present invention, medical images of any one imaging device, such as Computed Tomography (CT), Angiography (Angiography), Nuclear Magnetic Resonance Imaging (NMRI), and the like, may be acquired according to the DICOM standard.
It can be understood that, when a doctor wants to diagnose a dicom source file in any imaging device, the doctor wants to send an acquisition request to the imaging device through a client for acquiring images;
it can be understood that, if the imaging device has finished shooting the image, i.e., the dicom source file, when receiving the acquisition request sent by the image acquisition client, the imaging device sends an acquisition response, and the image acquisition client extracts the dicom source file from the acquisition response; if the imaging device does not finish shooting the image, namely the dicom source file, when receiving the acquisition request sent by the image acquisition client, the imaging device sends out a delay response including a preset delay time, so that the image acquisition client receives the dicom source file fed back by the imaging device after waiting for the preset delay time.
In the embodiment of the present invention, the acquiring corresponding text data and image data according to a DICOM source file includes:
intercepting images from a DICOM source file according to frames to obtain a plurality of images with corresponding frame numbers, and virtually printing the plurality of images in a preset typesetting format through a virtual printer to obtain a typesetting image containing the plurality of images;
and performing preset format conversion on the typeset image to obtain corresponding text data and image data in a preset format file.
It can be understood that the DICOM source file is a medical image which is shot by a patient through any imaging device according to the DICOM standard, and after the DICOM source file is received, the image needs to be intercepted for the convenience of the doctor or the patient to view.
It should be noted that the DICOM standard covers almost all information exchange protocols of acquisition, archiving, communication, display, query and the like of medical digital images, so that diagnostic images are intercepted from images according to frames through the DICOM acquisition standard, and because the diagnosis of a patient needs to view an affected part in all directions to obtain an accurate diagnosis result, the image needing to be intercepted is not only one frame, and after a plurality of diagnostic images are obtained, the plurality of images are typeset in a preset typesetting format through a DICOM virtual printer and then are subjected to virtual printing to obtain the DICOM images.
It can be understood that, based on the specific image format, firstly, the image is caused to contain a large amount of text and image information, and secondly, the reader used in the viewing is also specific, so that when the image is viewed or transmitted, not only much disk space and operating memory are occupied, but also a reader supporting the format needs to be installed, and in order to make the image more convenient to view, the file format needs to be converted into a common format.
The method for converting the preset format of the typeset image to obtain the corresponding text data and image data in the preset format file comprises the following steps:
converting the typesetting image into an XML format file to obtain text data in the XML format file;
and (4) the typeset images are packaged into portable network picture png format files and destructive image jpeg format files, and image data in the png format files and the jpeg format files are obtained.
In the embodiment of the present invention, the xml format file is a file obtained by reading the non-image data portion in the layout image.
In the embodiment of the present invention, the portable network picture png format file is a file obtained by reading the image data portion in the layout image.
In the embodiment of the present invention, the destructive image jpeg format file is a file obtained by reading the image data portion in the layout image and performing down-sampling.
It is understood that the compression algorithm compresses data corresponding to text or images, and thus extracts desired text data and image data from the above-described format.
The reason for extracting the data after the DICOM image is converted into the preset format is two: first, to save time; secondly, in order to obtain an image which is easy to view when decompressing.
It should be noted that, data can be directly extracted from a DICOM image, but due to the special format, conversion of many algorithms is required, so that the extraction process cannot be performed quickly and stably, a lot of time is wasted, and the extraction efficiency is reduced.
In the embodiment of the invention, the DICOM image is converted into the xml format file, the png format file and the jpeg format file, and then the data is extracted, so that the compressed file can obtain the file format which is convenient to view after being decompressed without being converted again.
202. Analyzing DICOM source files, text data and image data by using a preset protocol to obtain compressed data;
203. performing data merging storage on the compressed data in a byte array mode to obtain a target file;
in the embodiment of the present invention, the preset protocol may be a dicom3.0 protocol or any other protocol that can be resolved. And further analyzing the DICOM source file, the text data and the image data through a preset protocol, extracting all data to be compressed as compressed data, and merging and storing the compressed data in a byte array form to obtain a target file.
204. And compressing the target file by using a preset compression algorithm to obtain a target compressed file.
The content related to step 204 included in the compression method for browser rendering data in the embodiment of the present invention shown in fig. 2 is similar to the content related to step 103 in the compression method for browser rendering data in the embodiment shown in fig. 1, and specifically, the content described in step 103 in fig. 1 may be referred to, which is not described herein again.
In the embodiment of the present invention, compressing the target file by using a preset compression algorithm to obtain the target compressed file, and then further includes:
if a storage request is received, storing the target compressed file to a disk;
and if the transmission request is received, the target compressed file is stored to a disk and then transmitted to the request sending client.
In the embodiment of the invention, after the target file is compressed in the memory to obtain the target compressed file, the target compressed file needs to be stored in the disk, and when other clients, namely the patient end or other doctor seeing ends send transmission requests, the stored target compressed file is transmitted to the corresponding client.
The method comprises the steps of receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data; using a preset protocol to analyze a DICOM source file, text data and image data to obtain compressed data; performing data merging storage on the compressed data in a byte array mode to obtain a target file; and compressing the target file by using a preset compression algorithm to obtain a target compressed file. The target files obtained by merging the compressed data in a byte array mode are compressed, so that the compression range is further reduced, the obtained target compressed files are stored to a disk, the occupied space is less, the enterprise cost is reduced, and the transmission speed is higher when the target compressed files are transmitted to other clients for reference.
To better understand the embodiment of the present invention, as shown in fig. 3, a further flowchart of a method for compressing browser browsing data according to the embodiment of the present invention is shown, where the method shown in fig. 3 specifically includes the following steps:
301. receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data;
302. analyzing DICOM source files, text data and image data by using a preset protocol to obtain compressed data;
303. performing data merging storage on the compressed data in a byte array mode to obtain a target file;
the contents related to steps 301, 302, and 303 included in the compression method for browser rendering data according to the embodiment of the present invention shown in fig. 3 are similar to the contents of steps 101, 201, 202, and 203 in the compression method for browser rendering data according to the embodiment shown in fig. 1 and fig. 2, and specifically refer to the contents described in steps 101, 201, 202, and 203 in fig. 1 and fig. 2, which are not repeated herein.
304. Calculating the length of memory bytes occupied by the target file to obtain the length of bytes to be compressed;
it is understood that, before compressing the target file, the length of the bytes to be compressed of the target compressed file needs to be determined, and other calculation methods may be performed by using a function in C language, a function in JAVA, and the like, which is not limited in this example.
Taking the calculation by using the function in the C language as an example, further details are given as follows:
(1) calling an ifstream function to open a file to be calculated;
(2) calling a seekg function to set the get pointer as the end of the file, seekg (0, ios _ base:: end);
(3) calling a tellg function to obtain the total byte number, wherein the actually obtained offset byte number of the get pointer relative to the file header;
(4) reset get pointer to point to the header so as to execute other operations seekg (0, ios:: beg);
for each read of a file by the ifstream, the ifstream can be called, wherein gcount obtains the number of bytes read, the return value of gcount is streamsize, and streamsize is integer, signed int or signed long.
It is to be understood that the above examples are illustrative only and not limiting in any way
305. And determining a compression parameter of a preset compression algorithm according to the length of the byte to be compressed, and compressing the target file by using the compression parameter to obtain the target compressed file.
It can be understood that LZ77 encoding is a dictionary-based lossless compression algorithm, widely used in communication, computer file archiving, etc., and encodes long character strings (also called phrases) into short labels, and replaces the phrases in the dictionary with small labels, thereby achieving the purpose of compression. That is, it compresses data by replacing a long string of multiple repeated occurrences in the data with small marks. The symbols to be processed are not necessarily text characters, and may be symbols of any size. Different dictionary-based algorithms use different methods to maintain their dictionaries, LZ77 using a forward buffer and a sliding window.
Where LZ77 first loads a portion of the data into the forward buffer, in order to facilitate understanding how the forward buffer stores phrases and forms a dictionary:
first, we depict the buffer as a character sequence of S1, …, Sn, and Pb is a set of phrases consisting of characters, n phrases being composed from the character sequence S1, …, Sn, defined as follows:
pb { (S1), (S1, S2), …, (S1, …, Sn) }, e.g., if the forward buffer contains a character (a, B, D), then the phrase in the buffer is { (a), (a, B, D) };
second, once a phrase in the data passes through the forward buffer, it will move into the sliding window and become part of the dictionary. To better understand how phrases are represented in a sliding window, first, imagine the sliding window as a sequence of characters of S1, …, Sm, and Pw is a phrase set composed of these characters, the process of generating a phrase data set from the sequences S1, …, Sm is as follows:
pw { (Si), (Si, Si +1), …, (Si, Si +1, …, Sm) }, for example, if the symbol (a, B, C) is included in the sliding window, then the phrases in the window and the dictionary are { (a), (a, B, C), (B, C), (C) };
it will be appreciated that the main idea of the LZ77 algorithm is to continually find the longest phrase in the forward buffer that can be matched to the phrase in the dictionary. Taking the forward buffer and sliding window described above as examples, the longest matching phrase is (a, B).
There are two cases of matching between the forward buffer and the sliding window: either a matching phrase is found or no matching phrase is found. When the longest match is found, it is encoded as a phrase marker.
Wherein the phrase token contains three parts: 1. offset in sliding window: the previous character from the head to the start of the match; 2. the number of symbols in the matching; 3. after the matching is over, the first symbol in the forward buffer.
It will be appreciated that when no match is found, the unmatched symbol is encoded into a symbol tag. This symbol mark contains only the symbol itself and no compression process. In fact, we will see that the symbol mark is actually one bit more than the symbol, so slight spreading occurs.
It will be appreciated that once the n symbols have been encoded and the corresponding markers generated, the n symbols are removed from one end of the sliding window and replaced with the same number of symbols in the forward buffer. The forward buffer is then refilled. This process keeps the most recent phrase in the sliding window. The number of phrases specifically maintained by the sliding window and the forward buffer is determined by their own capacity.
In the embodiment of the present invention, a preset algorithm is an LZ77 algorithm, and an LZ77 algorithm is used to compress a character string abacbababcacad as an example, and a compression process is described as follows:
firstly, determining a compression parameter according to the byte length of a character string to be compressed, wherein the size of a sliding window is 8 bytes, and the size of a forward buffer is 4 bytes.
Next, the compression of the string ababcabacad is started:
starting: finding no matching phrase from the forward buffer ABAB in the sliding window, encoding a as the symbolic marker a;
finding no matching phrase from a forward buffer BABC in a sliding window A, and coding B into a symbol mark B;
finding phrase AB in sliding window AB from forward buffer ABCB, at the position of sliding window offset 6, coding AB into symbol mark (6, 2, C);
finding the phrase BAB from the forward buffer BABA in the sliding window ABABC at the position of the sliding window offset of 4, and coding the BAB into a symbol mark (4, 3, A);
finding phrase BC at the position with the sliding window offset of 2 in a forward buffer area BCAD in a sliding window BABCBABA, and marking BC code as (2, 2, A);
sixthly, encoding D as a symbol mark D in the sliding window CBABABCA from the forward buffer D, wherein D is not found in the sliding window.
Finally, the string abacbababcap is compressed to AB (6, 2, C) (4, 3, a) (2, 2, a) D.
It is to be understood that the above-described compression process is an example of a compression process for better understanding LZ77 encoding, and is not particularly limited.
The method comprises the steps of receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data; using a preset protocol to analyze a DICOM source file, text data and image data to obtain compressed data; performing data merging storage on the compressed data in a byte array mode to obtain a target file; calculating the length of the target file occupied memory bytes to obtain the length of bytes to be compressed; and determining a compression parameter of a preset compression algorithm according to the length of the byte to be compressed, and compressing the target file by using the compression parameter to obtain the target compressed file. The target files obtained by merging the compressed data in a byte array mode are compressed, so that the compression range is further reduced, the obtained target compressed files are stored to a disk, the occupied space is less, the enterprise cost is reduced, and the transmission speed is higher when the target compressed files are transmitted to other clients for looking up.
Fig. 4 is a schematic structural diagram of a compressing apparatus for browser interpretation data according to an embodiment of the present invention, including:
the receiving module 401: the system is used for receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data;
the extraction module 402: the system comprises a DICOM source file, a text data and an image data, a target file and a database, wherein the DICOM source file is used for storing the text data and the image data;
the compression module 403: and the target file compression module is used for compressing the target file by using a preset compression algorithm to obtain a target compressed file.
Fig. 4 shows the content related to the steps included in each module of the compressing apparatus for browser rendering data according to the embodiment of the present invention, which is similar to the content of the steps in the compressing method for browser rendering data according to the embodiment shown in fig. 1, and specifically refers to the content described in the step shown in fig. 1, which is not described herein again.
The method comprises the steps of receiving a medical digital imaging and communication DICOM source file, and acquiring corresponding text data and image data according to the DICOM source file, wherein the DICOM source file is browser film reading data; extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file; and compressing the target file by using a preset compression algorithm to obtain a target compressed file. By extracting compressed data from the DICOM source file, the text data and the image data, the compressed data is simplified relative to the original file, so that the storage length of the target compressed file obtained after the target file is compressed by using a compression algorithm is further reduced, the occupation of the disk space is reduced, and the enterprise cost is reduced.
Fig. 5 is a diagram illustrating an internal structure of a computer electronic device according to an embodiment of the present invention. The computer device may be a terminal or a server. As shown in fig. 5, the computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and may also store a computer program that, when executed by the processor, causes the processor to implement the age identification method. The internal memory may also have a computer program stored therein, which when executed by the processor, causes the processor to perform the age identification method. Those skilled in the art will appreciate that the architecture shown in fig. 5 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In an embodiment of the present invention, a computer device is provided, which includes a memory and a processor, the memory stores a computer program, and the computer program, when executed by the processor, causes the processor to execute the steps recited in the above-mentioned embodiments of the present invention.
In an embodiment of the present invention, a computer-readable storage medium is provided, which stores a computer program, and when the computer program is executed by a processor, the computer program causes the processor to execute the steps described in the above embodiment of the present invention.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a non-volatile computer-readable storage medium, and can include the processes of the embodiments of the methods described above when the program is executed. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1.一种浏览器阅片数据的压缩方法,其特征在于,所述方法在内存中执行,所述方法包括:1. a compression method of browser reading data, is characterized in that, described method is carried out in memory, described method comprises: 接收医学数字成像和通信DICOM源文件,根据所述DICOM源文件获取到对应的文本数据及图像数据,所述DICOM源文件为所述浏览器阅片数据;Receive medical digital imaging and communication DICOM source files, obtain corresponding text data and image data according to the DICOM source files, and the DICOM source files are the browser reading data; 根据所述DICOM源文件、所述文本数据及图像数据提取压缩数据,得到目标文件;Extract compressed data according to the DICOM source file, the text data and the image data to obtain a target file; 使用预设压缩算法压缩所述目标文件,获得目标压缩文件。The target file is compressed using a preset compression algorithm to obtain a target compressed file. 2.根据权利要求1所述方法,其特征在于,所述根据所述DICOM源文件、所述文本数据及图像数据提取压缩数据,得到目标文件,包括:2. method according to claim 1, is characterized in that, described extracting compressed data according to described DICOM source file, described text data and image data, obtains target file, comprises: 使用预设协议对所述DICOM源文件、所述文本数据及图像数据进行解析,获得压缩数据;Using a preset protocol to parse the DICOM source file, the text data and the image data to obtain compressed data; 将所述压缩数据以字节数组方式进行数据合并存储,获得所述目标文件。The compressed data is combined and stored in the form of a byte array to obtain the target file. 3.根据权利要求1所述方法,其特征在于,所述根据所述DICOM源文件获取到对应的文本数据及图像数据,包括:3. method according to claim 1, is characterized in that, described according to described DICOM source file to obtain corresponding text data and image data, comprising: 将所述DICOM源文件按帧截取图像,获得多张对应帧数的图像,将所述多张图像以预设排版格式通过虚拟打印机虚拟打印获得一张包含所述多张图像的排版图像;The DICOM source file is intercepted by frame, and a plurality of images corresponding to the number of frames are obtained, and a typesetting image comprising the multiple images is obtained by virtual printing of the multiple images in a preset typesetting format by a virtual printer; 将所述排版图像进行预设格式转换,获取预设格式文件中对应的文本数据及图像数据。Perform preset format conversion on the typesetting image to obtain corresponding text data and image data in the preset format file. 4.根据权利要求3所述方法,其特征在于,所述将所述排版图像进行预设格式转换,获取预设格式文件中对应的文本数据及图像数据,包括:4. The method according to claim 3, wherein the typesetting image is subjected to preset format conversion to obtain corresponding text data and image data in the preset format file, comprising: 将所述排版图像转换为可扩展标记语言xml格式文件,获取所述xml格式文件中的所述文本数据;Converting the typesetting image into an extensible markup language xml format file, and obtaining the text data in the xml format file; 将所述排版图像装换为便携式网络图片png格式文件和破坏性图像jpeg格式文件,获取所述png格式文件和所述jpeg格式中的所述图像数据。The typesetting image is replaced with a portable network picture png format file and a destructive image jpeg format file, and the image data in the png format file and the jpeg format is obtained. 5.根据权利要求1所述方法,其特征在于,所述使用预设压缩算法压缩所述目标文件,获得目标压缩文件,包括:5. The method according to claim 1, characterized in that, using a preset compression algorithm to compress the target file to obtain the target compressed file, comprising: 计算所述目标文件占用内存字节长度,得到待压缩字节长度;Calculate the byte length of the memory occupied by the target file to obtain the byte length to be compressed; 根据所述待压缩字节长度,确定预设压缩算法的压缩参数,利用压缩参数对所述目标文件压缩,获得目标压缩文件。According to the length of the bytes to be compressed, the compression parameters of the preset compression algorithm are determined, and the target file is compressed by using the compression parameters to obtain the target compressed file. 6.根据权利要求1所述方法,其特征在于,所述使用预设压缩算法压缩所述目标文件,获得目标压缩文件,之后还包括:6. The method according to claim 1, wherein the using a preset compression algorithm to compress the target file to obtain the target compressed file, further comprising: 若接收到保存请求,则将所述目标压缩文件保存至磁盘;If a save request is received, the target compressed file is saved to the disk; 若接收到传输请求,则将所述目标压缩文件保存至磁盘后传输至发出请求客户端。If a transmission request is received, the target compressed file is saved to the disk and then transmitted to the requesting client. 7.根据权利要求1所述方法,其特征在于,所述接收医学数字成像和通信DICOM源文件,之前还包括:7. The method according to claim 1, characterized in that, before said receiving medical digital imaging and communication DICOM source files, it further comprises: 向成像设备发出源文件获取请求;Issue a source file acquisition request to the imaging device; 若接收到源文件获取响应,则从所述源文件获取响应中提取所述DICOM源文件;If a source file acquisition response is received, extract the DICOM source file from the source file acquisition response; 若接收到源文件延迟响应,则等待预设延迟时长后接收所述成像设备反馈的DICOM源文件。If a source file delay response is received, the DICOM source file fed back by the imaging device is received after a preset delay time. 8.一种浏览器阅片数据的压缩传输装置,其特征在于,包括:8. A compression transmission device for browser reading data, characterized in that, comprising: 接收模块:用于接收医学数字成像和通信DICOM源文件,根据所述DICOM源文件获取到对应的文本数据及图像数据,所述DICOM源文件为所述浏览器阅片数据;Receiving module: used to receive medical digital imaging and communication DICOM source files, obtain corresponding text data and image data according to the DICOM source files, and the DICOM source files are the browser reading data; 提取模块:用于根据所述DICOM源文件、所述文本数据及图像数据提取压缩数据,得到目标文件;Extraction module: for extracting compressed data according to the DICOM source file, the text data and the image data to obtain a target file; 压缩模块:用于使用预设压缩算法压缩所述目标文件,获得目标压缩文件。Compression module: used to compress the target file using a preset compression algorithm to obtain a target compressed file. 9.一种设备,其特征在于,包括存储器和处理器,所述存储器存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行如权利要求1至7中任一项所述的浏览器阅片数据的压缩方法的步骤。9. A device, comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor causes the processor to perform any one of claims 1 to 7. One of the steps of the method for compressing browser reading data. 10.一种计算机可读存储介质,其特征在于,存储有计算机程序,所述计算机程序被处理器执行时,使得所述处理器执行如权利要求1至7中任一项所述的浏览器阅片数据的压缩方法的步骤。10. A computer-readable storage medium, characterized in that a computer program is stored, and when the computer program is executed by a processor, the processor is made to execute the browser according to any one of claims 1 to 7 The steps of the compression method of reading data.
CN202011270114.XA 2020-11-13 2020-11-13 Compression method, device, equipment and storage medium for browser film reading data Pending CN112599223A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011270114.XA CN112599223A (en) 2020-11-13 2020-11-13 Compression method, device, equipment and storage medium for browser film reading data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011270114.XA CN112599223A (en) 2020-11-13 2020-11-13 Compression method, device, equipment and storage medium for browser film reading data

Publications (1)

Publication Number Publication Date
CN112599223A true CN112599223A (en) 2021-04-02

Family

ID=75182944

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011270114.XA Pending CN112599223A (en) 2020-11-13 2020-11-13 Compression method, device, equipment and storage medium for browser film reading data

Country Status (1)

Country Link
CN (1) CN112599223A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116347078A (en) * 2022-04-12 2023-06-27 浙江卡易智慧医疗科技有限公司 DICOM real-time image coding method and system based on image cloud

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008142915A1 (en) * 2007-05-21 2008-11-27 Konica Minolta Medical & Graphic, Inc. Medical image management device and program
US20090313170A1 (en) * 2008-06-16 2009-12-17 Agmednet, Inc. Agent for Medical Image Transmission
US20100080476A1 (en) * 2008-10-01 2010-04-01 Elahe Khorasani Methods and systems for proxy medical image compression and transmission
US20160119582A1 (en) * 2013-03-15 2016-04-28 James Paul Smurro Neurosynaptic network connectivity and collaborative knowledge exchange with visual neural networking and packetized augmented cognition
US20180322254A1 (en) * 2017-05-02 2018-11-08 James Paul Smurro Multimodal cognitive collaboration and cybernetic knowledge exchange with visual neural networking streaming augmented medical intelligence

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008142915A1 (en) * 2007-05-21 2008-11-27 Konica Minolta Medical & Graphic, Inc. Medical image management device and program
US20090313170A1 (en) * 2008-06-16 2009-12-17 Agmednet, Inc. Agent for Medical Image Transmission
US20100080476A1 (en) * 2008-10-01 2010-04-01 Elahe Khorasani Methods and systems for proxy medical image compression and transmission
US20160119582A1 (en) * 2013-03-15 2016-04-28 James Paul Smurro Neurosynaptic network connectivity and collaborative knowledge exchange with visual neural networking and packetized augmented cognition
US20180322254A1 (en) * 2017-05-02 2018-11-08 James Paul Smurro Multimodal cognitive collaboration and cybernetic knowledge exchange with visual neural networking streaming augmented medical intelligence

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116347078A (en) * 2022-04-12 2023-06-27 浙江卡易智慧医疗科技有限公司 DICOM real-time image coding method and system based on image cloud

Similar Documents

Publication Publication Date Title
WO2022017085A1 (en) Dicom file processing method, device and system
JP2015509294A (en) Encode high quality (medical) images using standard low quality (web) image formats
CN107145730A (en) DICOM medical images file reads adaption system
US20160267649A1 (en) Low latency web-based dicom viewer system
Bhagat et al. Medical images: Formats, compression techniques and DICOM image retrieval a survey
US20050207658A1 (en) Method and apparatus for extracting information from a medical image
Rahmat et al. Analysis of dicom image compression alternative using huffman coding
US20150201020A1 (en) Method and apparatus for storing network data
CN110598025A (en) Image reading method, system, apparatus, device and storage medium
CN112599223A (en) Compression method, device, equipment and storage medium for browser film reading data
CN113538253B (en) Medical image processing method, medium and CT device
JP2010022821A (en) Method and apparatus for ct image compression
JP2010022821A6 (en) CT image compression method and apparatus
JPH11213144A (en) Image storing method and image output system
JP2006325725A (en) Medical information management device, medical information management system, medical information management method, and medical information management program
US20080130967A1 (en) Compression and decompression of medical images
JPWO2008142915A1 (en) Medical image management apparatus and program
CN116312919A (en) Medical detection report generation method, device, equipment and storage medium
CN110310725B (en) DICOM image display method and device
KR102199494B1 (en) Apparatus and method for managing medical image
JP4872837B2 (en) MEDICAL IMAGE MANAGEMENT DEVICE, MEDICAL IMAGE SYSTEM, AND PROGRAM
Rusev A module for visualisation and analysis of digital images in DICOM file format.
CN112614567A (en) Medical image processing method, device and server
CN112365958A (en) DICOM file information reading and image format conversion method
CN112863647A (en) Video stream processing and displaying method, system and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210402