Method for preventing digital film packet from being transmitted repeatedly

文档序号:765871 发布日期:2021-04-06 浏览:8次 中文

阅读说明:本技术 一种避免数字电影包重复传输的方法 (Method for preventing digital film packet from being transmitted repeatedly ) 是由 李军 林晓飞 于 2020-12-09 设计创作,主要内容包括:本发明的一个实施例公开了一种避免数字电影包重复传输的方法,包括:S10:发送端生成待发送dcp目录的种子文件,并发送给接收端;S13:接收端根据所述种子文件判断所述dcp中是否含有本地资源已有资源;S15:发送端发送dcp中接收端本地未含有的dcp文件;S17:接收端接收完成后,将所述本地资源已有资源复制到接收到的dcp文件目录中。(One embodiment of the invention discloses a method for avoiding repeated transmission of digital movie packets, which comprises the following steps: s10, the sending end generates a seed file of the to-be-sent dcp directory and sends the seed file to the receiving end; s13, the receiving end judges whether the dcp contains the existing resources of the local resources according to the seed file; s15, the sending end sends the dcp file which is not contained in the dcp at the receiving end; and S17, after the receiving end finishes receiving, copying the existing resources of the local resources to the received dcp file directory.)

1. A method for avoiding duplicate transmission of digital cinema packages, comprising:

s10, the sending end generates a seed file of the to-be-sent dcp directory and sends the seed file to the receiving end;

s13, the receiving end judges whether the dcp contains the existing resources of the local resources according to the seed file;

s15, the sending end sends the dcp file which is not contained in the dcp at the receiving end;

and S17, after the receiving end finishes receiving, copying the existing resources of the local resources to the received dcp file directory.

2. The method of claim 1, further comprising: prior to the time of the said S10,

acquiring mxf files to be sent dcp and all files in the receiving end library which are larger than a preset threshold value,

the hash value of the mxf file is calculated,

mxf files with the same name and the same directory and the same hash value are stored in the resource mapping table, and different hash values are stored in the resource mapping table respectively.

3. The method according to claim 1, wherein the S13 includes:

the receiving end analyzes the seed file to obtain a directory of files in the dcp;

acquiring a hash value of a corresponding file under a directory in a mapping table of a sending end;

and inquiring whether the files in the receiving end chip library are completely the same or not according to the hash value, the file name and the file size of the files, if the files are the same, recording the files as local existing resources, and if the files are not the same, recording the files as dcp files which are not locally contained.

4. The method of claim 2, wherein when a new dcp is added at a receiving end or a transmitting end,

and when the dcp is imported, calculating the hash value of the file in the dcp, and adding the new hash value into the resource mapping table.

5. The method according to claim 4, wherein the dcp file which is marked as not locally contained is sent only once for the file under the same hash value in the resource mapping table.

6. The method of claim 1, wherein the resource mapping table comprises: file name, hash value and file value of the file.

7. The method according to any of claims 1-6, wherein the receiving end sends the complete dcp directory file to the service end after completing the S17.

8. A computer device comprising a processor and a memory having stored thereon a computer program, characterized in that the processor, when executing the program, implements the method according to any of claims 1-7.

9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1-7.

Technical Field

The present invention relates to the field of data transmission. And more particularly, to a method of preventing duplicate transmission of digital cinema packages.

Background

The dcp in the movie industry is a format for storing movie digital content, which is typically hundreds of G in size, because multiple versions are often packaged for transmission in different versions. However, since a significant portion of a file resource file, such as a media file, is duplicated between different versions. This results in a significant repetition, which is a significant waste of the resources occupied by the movie, especially the transmission bandwidth. Even if a p2p network is used for distribution and multiple dcp movie file packages are sent respectively, the problems that the dcp data volume is too large, excessive network bandwidth and transmission time are occupied, and further the cost is high are still faced.

Disclosure of Invention

In view of the above, a first embodiment of the present invention provides a method for preventing duplicate transmission of digital cinema packages, comprising:

s10, the sending end generates a seed file of the to-be-sent dcp directory and sends the seed file to the receiving end;

s13, the receiving end judges whether the dcp contains the existing resources of the local resources according to the seed file;

s15, the sending end sends the dcp file which is not contained in the dcp at the receiving end;

and S17, after the receiving end finishes receiving, copying the existing resources of the local resources to the received dcp file directory.

In a particular embodiment, the method further comprises: prior to the time of the said S10,

acquiring mxf files to be sent dcp and all files in the receiving end library which are larger than a preset threshold value,

the hash value of the mxf file is calculated,

mxf files with the same name and the same directory and the same hash value are stored in the resource mapping table, and different hash values are stored in the resource mapping table respectively.

In a specific embodiment, the S13 includes:

the receiving end analyzes the seed file to obtain a directory of files in the dcp;

acquiring a hash value of a corresponding file under a directory in a mapping table of a sending end;

and inquiring whether the files in the receiving end chip library are completely the same or not according to the hash value, the file name and the file size of the files, if the files are the same, recording the files as local existing resources, and if the files are not the same, recording the files as dcp files which are not locally contained.

In a particular embodiment, when a new dcp is added at the receiving or transmitting end,

and when the dcp is imported, calculating the hash value of the file in the dcp, and adding the new hash value into the resource mapping table.

In a specific embodiment, the dcp file which is marked as not locally contained is sent only once for the file under the same hash value in the resource mapping table.

In a specific embodiment, the resource mapping table includes: file name, hash value and file value of the file.

In a specific embodiment, after completing the step S17, the receiving end sends the file in the complete dcp directory to the service end.

A second embodiment of the present invention provides a computer device, comprising a processor and a memory storing a computer program, wherein the processor executes the program to implement the method according to any one of the first embodiment.

A third embodiment of the invention provides a computer-readable storage medium, on which a computer program is stored, characterized in that the program, when executed by a processor, implements the method according to any one of the first embodiments.

The invention has the following beneficial effects:

according to the application, through finding and processing repeated dcp file packets at a sending end and through specific processing, in the transmission process of p2p, repeated files are not transmitted for many times, but only one copy is transmitted, and at a receiving end, resource files are recovered according to the existing dcp file packets at local and through the design of the technical scheme. The transmission quantity of multi-version repeated resources in the digital movie package is reduced, so that the transmission efficiency and the bandwidth occupation are improved, and decentralized distribution to a large number of receiving ends by the dcp is supported.

Drawings

In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.

Fig. 1 shows a hardware architecture diagram of a method of avoiding duplicate transmission of digital cinema packages according to one embodiment of the present invention.

Fig. 2 shows a flow diagram of a method of avoiding duplicate transmission of digital cinema packages according to one embodiment of the present invention.

Fig. 3 shows a schematic structural diagram of a computer device according to another embodiment of the present invention.

Detailed Description

In order to make the technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be described in detail with reference to the accompanying drawings.

As shown in fig. 1, a hardware architecture diagram of a method for avoiding repeated transmission of Digital Cinema packages, a sending end 10, for example, a chinese movie company, ltd, sends Digital Cinema packages (Digital Cinema Package DCP) to each receiving end 13 through a p2 p-based file transmission network 15. The receiving end is shown as 1, however, those skilled in the art can understand that in the practical application scenario, the receiving end is multiple, for example, movie theaters distributed in various cities.

As shown in fig. 2, a method for avoiding duplicate transmission of digital cinema packages comprises:

acquiring mxf files to be sent dcp and all files in the receiving end library which are larger than a preset threshold value,

the hash value of the mxf file is calculated,

mxf files with the same name and the same directory and the same hash value are stored in the resource mapping table, namely, one hash value in the resource mapping table may correspond to a plurality of mxf files in a plurality of dcp files, and different hash values are stored in the resource mapping table respectively.

In one specific example, the format: hash dcpname path/file size

I.e. hash ═ dcp, filename, size

S10, the sending end generates a seed file of the to-be-sent dcp directory and sends the seed file to the receiving end;

s13, the receiving end judges whether the dcp contains the existing resources of the local resources according to the seed file;

the receiving end analyzes the seed file to obtain a directory of files in the dcp, wherein the directory comprises the name and the size of each file in the dcp;

inquiring the api of the sending end through a network, then obtaining the hash value of the corresponding file under the directory in the mapping table of the sending end, and recording the hash value;

and inquiring whether the files in the receiving end chip library are completely the same or not according to the hash value, the file name and the file size of the files, if the files are the same, recording the files as local existing resources, and if the files are not the same, recording the files as dcp files which are not locally contained.

S15, the sending end sends the dcp file which is not contained in the dcp at the receiving end;

and S17, after the receiving end finishes receiving, copying the existing resources of the local resources to the received dcp file directory.

In a specific embodiment, after completing the step S17, the receiving end sends the file in the complete dcp directory to the service end.

In a specific embodiment, when a new dcp is added at a receiving end or a sending end, a local mapping table is updated in real time, a hash value of a file in the dcp is calculated in real time, and the new hash value is added to a resource mapping table.

Another embodiment of the present invention provides a computer readable storage medium having stored thereon a computer program, which when executed by a processor, implements any combination of one or more computer readable media in a practical application. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present embodiment, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.

As shown in fig. 3, another embodiment of the present invention provides a schematic structural diagram of a computer device. The computer device 12 shown in FIG. 3 is only an example and should not impose any limitation on the scope of use or functionality of embodiments of the present invention.

As shown in FIG. 3, computer device 12 is in the form of a general purpose computing device. The components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, and a bus 18 that couples various system components including the system memory 28 and the processing unit 16.

Bus 18 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. By way of example, such architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, micro-channel architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.

Computer device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by computer device 12 and includes both volatile and nonvolatile media, removable and non-removable media.

The system memory 28 may include computer system readable media in the form of volatile memory, such as Random Access Memory (RAM)30 and/or cache memory 32. Computer device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 3, and commonly referred to as a "hard drive"). Although not shown in FIG. 3, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 18 by one or more data media interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the invention.

A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, in memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally carry out the functions and/or methodologies of the described embodiments of the invention.

Computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with computer device 12, and/or with any devices (e.g., network card, modem, etc.) that enable computer device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O) interface 22. Also, computer device 12 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) via network adapter 20. As shown in FIG. 3, the network adapter 20 communicates with the other modules of the computer device 12 via the bus 18. It should be understood that although not shown in FIG. 3, other hardware and/or software modules may be used in conjunction with computer device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.

The processor unit 16 executes various functional applications and data processing by executing programs stored in the system memory 28, for example, to implement a method for preventing duplicate transmission of digital cinema packages according to an embodiment of the present invention.

It should be understood that the above-mentioned embodiments of the present invention are only examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention, and it will be obvious to those skilled in the art that other variations or modifications may be made on the basis of the above description, and all embodiments may not be exhaustive, and all obvious variations or modifications may be included within the scope of the present invention.

8页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种视频水印添加方法、系统、介质及电子终端

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类