Git Product home page Git Product logo

Comments (4)

LemurPwned avatar LemurPwned commented on September 1, 2024 1

As it seems only IdiotenProof solution is to do smth like this

number_of_files = len(files_in_directory_with_extension)
odt_stages = len(odt_column)
if number_of_files < odt_stages:
  file_skip = odt_stages/number_of_files
else:
 file_skip = 0

from vism.

LemurPwned avatar LemurPwned commented on September 1, 2024

What exactly is happening can be found in multiprocessing_parse.py

if odt_file is not None:
     odt_data, _ = getOdtData(odt_file[0]) <--- here the second arguments is stages
### stages in odt_data > number of files in directory
else:
     odt_data = None
stages = glob.glob(os.path.join(directory, '*' + ext)) 
test_file = os.path.join(directory, stages[0])

stages = len(stages) <--- stages are overwritten and match number of files

This is done now so that it does not cause an error.
What should happen, is we can take

odt_data, stages1 = getOdtData(odt_file[0]) <----- here the second arguments is stages
 ...
stages = len(stages)
stages_skip = int(stages1/stages)

from vism.

pawelkulig1 avatar pawelkulig1 commented on September 1, 2024

Not argument, but returned value?
Yes, but using getOdtData(), requires path to odt file, if it doesn't exist, we can't prove it. It requires changes in getOdtData function to handle None path or something like this.

from vism.

LemurPwned avatar LemurPwned commented on September 1, 2024

If no path then stages should be as they are right now

no returned value, it is unused right now

from vism.

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.