Coder Social home page Coder Social logo

Comments (3)

namtc14 avatar namtc14 commented on August 17, 2024

The error occurs due to the program continues to read frames though it has already reached the end of the video file.
For example, the following video sample is very short, not enough 27 frames to capture: https://www.signingsavvy.com/signs/mp4/7/7169.mp4

I am considering about solution: Check the returned value of VideoCapture.read() function
for offset in range(num): success, img = vidcap.read() if not success: break w, h, c = img.shape
Let's try and share the result

from wlasl.

dxli94 avatar dxli94 commented on August 17, 2024

Another common cause is your local copy of the dataset misses some video files. Do you use official WLASL release or download from somewhere? Note that re-distribution of WLASL is strictly prohibited.

from wlasl.

Nehajain1207 avatar Nehajain1207 commented on August 17, 2024

Hi,

I am opening an issue here since I am trying to run train_i3d.py, and I keep getting the same error. After trying a few things, it does not work. Here is the error, could anyone help me out please?

[Running] python -u "c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\train_i3dVersion2.py"
root {'word': 'C:\\Users\\siste\\OneDrive\\Desktop\\New folder\\archive\\videos'} train_split C:/Users/siste/OneDrive/Desktop/New folder/WLASL-master/WLASL-master/code/I3D/preprocess\nslt_2000.json
types of data run --- config <class 'configs.Config'> mode <class 'str'> root <class 'dict'> save_model <class 'str'> train_split <class 'str'> weights <class 'NoneType'>
bs=6_ups=1_lr=0.0001_eps=0.001_wd=1e-08
Skipped videos:  0
10566
Skipped videos:  0
1414
Step 0/64000
----------
c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\train_i3dVersion2.py:118: DeprecationWarning: `[np.int](http://np.int/)` is a deprecated alias for the builtin `int`. To silence this warning, use `int` by itself. Doing this will not modify any behavior and is safe. When replacing `[np.int](http://np.int/)`, you may wish to use e.g. `np.int64` or `np.int32` to specify the precision. If you wish to review your current use, check the release note link for additional information.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  (num_classes, num_classes), dtype=[np.int](http://np.int/))
dataloaders <torch.utils.data.dataloader.DataLoader object at 0x000001F76FEB5790>
Traceback (most recent call last):
  File "c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\train_i3dVersion2.py", line 220, in <module>
    run(configs=configs, mode=mode, root=root, save_model=save_model,
  File "c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\train_i3dVersion2.py", line 121, in run
    for data in dataloaders[phase]:
  File "C:\Python39\lib\site-packages\torch\utils\data\dataloader.py", line 517, in __next__
    data = self._next_data()
  File "C:\Python39\lib\site-packages\torch\utils\data\dataloader.py", line 557, in _next_data
    data = self._dataset_fetcher.fetch(index)  # may raise StopIteration
  File "C:\Python39\lib\site-packages\torch\utils\data\_utils\fetch.py", line 44, in fetch
    data = [self.dataset[idx] for idx in possibly_batched_index]
  File "C:\Python39\lib\site-packages\torch\utils\data\_utils\fetch.py", line 44, in <listcomp>
    data = [self.dataset[idx] for idx in possibly_batched_index]
  File "c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\datasets\nslt_dataset.py", line 191, in __getitem__
    imgs = load_rgb_frames_from_video(
  File "c:\Users\siste\OneDrive\Desktop\New folder\WLASL-master\WLASL-master\code\I3D\datasets\nslt_dataset.py", line 59, in load_rgb_frames_from_video
    w, h, c = img.shape
AttributeError: 'NoneType' object has no attribute 'shape'

you got the solution to it?

from wlasl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.