Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fine detect total parts video and audio for downloading, But wrong calculate audio parts after finish video... #575

Open
minzak opened this issue Dec 31, 2024 · 0 comments

Comments

@minzak
Copy link

minzak commented Dec 31, 2024

I'm trying download this url - https://kinescope.io/srWiSSjA5UFj35QdUgeEVH
If you see here is all data present in network, token with keys and mpd file.
At finally I run ./N_m3u8DL-RE https://kinescope.io/72666b48-d299-412f-a53d-7132dc7fd69b/master.mpd --save-name video --del-after-done=True --write-meta-json=True
After choose quality of downloaded

Please select what you want to download:                                                                              
                                                                                                                      
  [ ] Basic                                                                                                           
    [ ] Vid *CENC 1920x1080 | 4502 Kbps | 1150eded-fd21-425f-83a0-7fbf2128c2d5 | avc1.640028 | 876 Segments | ~58m23s 
    [ ] Vid *CENC 1280x720 | 3586 Kbps | b694d4b3-aaaf-468e-b592-61d76aa7eefc | avc1.4D401F | 876 Segments | ~58m23s  
    [ ] Vid *CENC 852x480 | 1663 Kbps | 3e2be68e-5bc9-4249-9249-ff125aee65be | avc1.4D401F | 876 Segments | ~58m23s   
  > [X] Vid *CENC 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E | 876 Segments | ~58m23s    
  [ ] Audio                                                                                                           
    [X] Aud *CENC ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en | 876 Segments | ~58m23s           
                                                                                                                      
(Press <space> to toggle a stream, <enter> to accept) 

I see:
877 parts in Video and 100 parts of Audio
877_100

But after downloaded Video - Audio parts a also 877, not as before - 100

877_877

And of course download, decode will fail..

How to fix it?

./N_m3u8DL-RE https://kinescope.io/72666b48-d299-412f-a53d-7132dc7fd69b/master.mpd --save-name video --del-after-done=True --write-meta-json=True
18:10:42.799 INFO : N_m3u8DL-RE (Beta version) 20241203
18:10:42.809 INFO : Loading URL: https://kinescope.io/72666b48-d299-412f-a53d-7132dc7fd69b/master.mpd
18:10:43.512 INFO : Content Matched: Dynamic Adaptive Streaming over HTTP
18:10:43.512 INFO : Parsing streams...
18:10:43.557 WARN : Writing meta json
18:10:43.562 INFO : Extracted, there are 5 streams, with 4 basic streams, 1 audio streams, 0 subtitle streams
18:10:43.562 INFO : Vid *CENC 1920x1080 | 4502 Kbps | 1150eded-fd21-425f-83a0-7fbf2128c2d5 | avc1.640028 | 876 Segments | ~58m23s
18:10:43.562 INFO : Vid *CENC 1280x720 | 3586 Kbps | b694d4b3-aaaf-468e-b592-61d76aa7eefc | avc1.4D401F | 876 Segments | ~58m23s
18:10:43.562 INFO : Vid *CENC 852x480 | 1663 Kbps | 3e2be68e-5bc9-4249-9249-ff125aee65be | avc1.4D401F | 876 Segments | ~58m23s
18:10:43.563 INFO : Vid *CENC 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E | 876 Segments | ~58m23s
18:10:43.563 INFO : Aud *CENC ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en | 876 Segments | ~58m23s
18:10:50.505 INFO : Parsing streams...
18:10:50.516 INFO : Selected streams:
18:10:50.516 INFO : Vid *CENC 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E | 876 Segments | ~58m23s
18:10:50.516 INFO : Aud *CENC ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en | 876 Segments | ~58m23s
18:10:50.516 WARN : Writing meta json
18:10:50.518 INFO : Save Name: video
18:10:50.519 INFO : Start downloading...Vid 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E
18:10:50.519 WARN : When CENC encryption is detected, binary merging is automatically enabled
18:10:50.768 WARN : Type: cbcs                                                        
18:10:50.768 WARN : KID: 74684b5a6277467176324153475a4d3d                             
18:10:50.769 WARN : Reading media info...                                             
18:10:50.849 INFO : [0x1]: Video, h264 (avc1), 640x360                                
18:13:52.008 WARN : video.mp4 => video.copy.mp4                                                              
18:13:52.009 INFO : Binary merging...                                                                        
18:13:52.417 INFO : Start downloading...Aud ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en 
18:13:52.662 WARN : Type: cbcs                                                                               
18:13:52.663 WARN : KID: 74684b5a6277467176324153475a4d3d                                                    
18:13:52.663 WARN : Reading media info...                                                                    
18:13:52.747 INFO : [0x1]: Audio, aac (mp4a), 192 kb/s                                                       
18:14:27.479 WARN : Force Exit...                                                                            
                                                                                                             
Vid 640x360 | 989 Kbps ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 877/877 100.00%        412.84MB     -      00:00:00    
Aud 193 Kbps | en      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━  216/877 24.63% 19.78MB/80.67MB 104.65KBps 00:01:46 ⢿  

And finally all is fail:

./N_m3u8DL-RE -M format=mkv --key UnhrZmpXc19aTXl4My1rPQ:alNzLW83MU0tMFo4VTlvPQ "https://kinescope.io/72666b48-d299-412f-a53d-7132dc7fd69b/master.mpd" --save-name video
18:36:06.422 INFO : N_m3u8DL-RE (Beta version) 20241203
18:36:06.432 INFO : Loading URL: https://kinescope.io/72666b48-d299-412f-a53d-7132dc7fd69b/master.mpd
18:36:07.050 INFO : Content Matched: Dynamic Adaptive Streaming over HTTP
18:36:07.050 INFO : Parsing streams...
18:36:07.089 WARN : Writing meta json
18:36:07.093 INFO : Extracted, there are 5 streams, with 4 basic streams, 1 audio streams, 0 subtitle streams
18:36:07.093 INFO : Vid *CENC 1920x1080 | 4502 Kbps | 1150eded-fd21-425f-83a0-7fbf2128c2d5 | avc1.640028 | 876 Segments | ~58m23s
18:36:07.093 INFO : Vid *CENC 1280x720 | 3586 Kbps | b694d4b3-aaaf-468e-b592-61d76aa7eefc | avc1.4D401F | 876 Segments | ~58m23s
18:36:07.093 INFO : Vid *CENC 852x480 | 1663 Kbps | 3e2be68e-5bc9-4249-9249-ff125aee65be | avc1.4D401F | 876 Segments | ~58m23s
18:36:07.094 INFO : Vid *CENC 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E | 876 Segments | ~58m23s
18:36:07.094 INFO : Aud *CENC ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en | 876 Segments | ~58m23s
18:36:12.219 INFO : Parsing streams...
18:36:12.226 INFO : Selected streams:
18:36:12.226 INFO : Vid *CENC 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E | 876 Segments | ~58m23s
18:36:12.226 INFO : Aud *CENC ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en | 876 Segments | ~58m23s
18:36:12.226 WARN : Writing meta json
18:36:12.228 INFO : Save Name: video
18:36:12.228 WARN : MuxAfterDone is detected, binary merging is automatically enabled
18:36:12.229 INFO : Start downloading...Vid 640x360 | 989 Kbps | 8d0fc960-2e88-4a4b-b25c-b68ea261ee0b | avc1.4D401E
18:36:12.473 WARN : Type: cbcs                                                        
18:36:12.474 WARN : KID: 74684b5a6277467176324153475a4d3d                             
18:36:12.474 WARN : Reading media info...                                             
18:36:12.555 INFO : [0x1]: Video, h264 (avc1), 640x360                                
18:39:50.456 INFO : Binary merging...                                                                       
18:39:50.835 WARN : Type: cbcs                                                                              
18:39:50.835 WARN : KID: 74684b5a6277467176324153475a4d3d                                                   
18:39:50.836 INFO : Decrypting using MP4DECRYPT...                                                          
18:39:50.836 INFO : Start downloading...Aud ac6301fb-015e-4707-9de4-ffbf6d35a963 | 193 Kbps | mp4a.40.2 | en
18:39:51.069 WARN : Type: cbcs                                                                              
18:39:51.070 WARN : KID: 74684b5a6277467176324153475a4d3d                                                   
18:39:51.070 WARN : Reading media info...                                                                   
18:39:51.152 INFO : [0x1]: Audio, aac (mp4a), 192 kb/s                                                      
18:41:25.670 INFO : Binary merging...                                                                        
18:41:25.786 WARN : Type: cbcs                                                                               
18:41:25.786 WARN : KID: 74684b5a6277467176324153475a4d3d                                                    
18:41:25.786 INFO : Decrypting using MP4DECRYPT...                                                           
18:41:25.787 WARN : video.mp4
18:41:25.787 WARN : video.en.m4a
18:41:25.788 WARN : Muxing to video.MUX.mkv
18:41:25.952 WARN : [h264 @ 0x56434fa559c0] top block unavailable for requested intra mode -1
18:41:25.953 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 0 0, bytestream 17189
18:41:25.954 WARN : [h264 @ 0x56434fa559c0] top block unavailable for requested intra mode
18:41:25.954 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 0 0, bytestream 4648
18:41:25.955 WARN : [h264 @ 0x56434fa559c0] Increasing reorder buffer to 2
18:41:25.955 WARN : [h264 @ 0x56434fa559c0] top block unavailable for requested intra mode
18:41:25.956 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 9 0, bytestream 1291
18:41:25.956 WARN : [h264 @ 0x56434fa559c0] Reference 3 >= 3
18:41:25.956 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 4 0, bytestream 6275
18:41:25.957 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 12 8, bytestream -12
18:41:25.957 WARN : [h264 @ 0x56434fa559c0] top block unavailable for requested intra mode
18:41:25.957 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 31 0, bytestream 720
18:41:25.958 WARN : [h264 @ 0x56434fa559c0] top block unavailable for requested intra mode
18:41:25.958 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 8 0, bytestream 1410
18:41:25.958 WARN : [h264 @ 0x56434fa559c0] Reference 4 >= 3
18:41:25.958 WARN : [h264 @ 0x56434fa559c0] error while decoding MB 1 0, bytestream 7054
18:41:26.060 WARN : [aac @ 0x5643528a74c0] Prediction is not allowed in AAC-LC.
18:41:26.061 WARN : [mov,mp4,m4a,3gp,3g2,mj2 @ 0x56434fa545c0] Incorrect number of samples in encryption info
18:41:26.061 WARN : /work/1/video.mp4: Invalid data found when processing input
18:41:26.061 WARN : [mov,mp4,m4a,3gp,3g2,mj2 @ 0x56435289d780] Incorrect number of samples in encryption info
18:41:26.061 WARN : /work/1/video.en.m4a: Invalid data found when processing input
18:41:26.172 WARN : Cleaning files...
18:41:26.221 WARN : Rename to video.mkv
18:41:26.221 INFO : Done

I'm also try do not use key when downloading.
But MD5hash - always the same. To use decrypt later - but it also not helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant