Giter Club home page Giter Club logo

Comments (6)

Karol-G avatar Karol-G commented on May 26, 2024 1

Ah yes that fixed it, thanks!

from gandlf.

Geeks-Sid avatar Geeks-Sid commented on May 26, 2024

Hi @Karol-G , Thanks for using GaNDLF.

It would be great if you comment out the line :

#parallel_compute_command: 'qsub -b y -l gpu -l h_vmem=32G -cwd -o ${outputDir}/\$JOB_ID.stdout -e ${outputDir}/\$JOB_ID.stderr `pwd`/sge_wrapper _correct_location_of_virtual_environment_/venv/bin/python'

so that it doesn't attempt to do a parallel compute, similarly, I would also recommend you to disable folded validation as:

nested_training:
  {
    testing: 1, # this controls the testing data splits for final model evaluation; use '1' if this is to be disabled
    validation: -5 # this controls the validation data splits for model training
  }

for running it once.

from gandlf.

Karol-G avatar Karol-G commented on May 26, 2024

I commented out parallel_compute_command and testing and validation instead of nested_training, else I get the error The parameter 'nested_training' needs to be defined.
But now i get the following error:

Using default folds for testing split:  -5
Using default folds for validation split:  -5
Using previously saved parameter file ./experiments/2d_classification/output_dir/parameters.pkl
Traceback (most recent call last):
  File "gandlf_run", line 75, in <module>
    main()
  File "gandlf_run", line 70, in main
    TrainingManager(dataframe=data_full, headers = headers, outputDir=model_path, parameters=parameters, device=device, reset_prev = reset_prev)
  File "/content/GaNDLF-refactor/GANDLF/training_manager.py", line 146, in TrainingManager
    device=device, params=parameters, testing_data=testingData)
  File "/content/GaNDLF-refactor/GANDLF/training_loop.py", line 322, in training_loop
    metrics = params["metrics"]
KeyError: 'metrics'

Seems a metric is missing. How do I define it for a classification task?

from gandlf.

sarthakpati avatar sarthakpati commented on May 26, 2024

HI @Karol-G,

You can add a key metrics in the parameter file with the value ['mse'] for classification. I will update this on the testing config for clarity.

Cheers,
Sarthak

from gandlf.

Karol-G avatar Karol-G commented on May 26, 2024

Hmm, I still get the same error with:

metrics:
  - mse

or:
metrics: ['mse']

from gandlf.

sarthakpati avatar sarthakpati commented on May 26, 2024

Ah, I think you need to try with this:

python gandlf_run -config ./experiments/2d_classification/model.yaml -data ./experiments/2d_classification/train.csv -output ./experiments/2d_classification/output_dir/ -train 1 -device cuda \
-reset_prev True # this will remove all writes to disk (such as training/validation data and parameters) from previous run

from gandlf.

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.