1

I am trying to use google colab for a project of mine but been stuck at this error since a long time. Any help would be highly appreciated. Here is my code snippet:

gpt2_simple.finetune(
    sess,
    dataset='input.txt',
    model_name='1.5B',
    steps=1000,
    restore_from='fresh',
    run_name='run1',
    print_every=10,
    sample_every=200,
    save_every=500
)

And the error:

JSONDecodeError                           Traceback (most recent call last)
<ipython-input-23-97af274a4eb8> in <module>()
      7               print_every=10,
      8               sample_every=200,
----> 9               save_every=500)

5 frames
/usr/lib/python3.6/json/decoder.py in raw_decode(self, s, idx)
    355             obj, end = self.scan_once(s, idx)
    356         except StopIteration as err:
--> 357             raise JSONDecodeError("Expecting value", s, err.value) from None
    358         return obj, end

JSONDecodeError: Expecting value: line 1 column 1 (char 0)
Martin Zeitler
  • 1
  • 19
  • 155
  • 216
shivang
  • 266
  • 3
  • 7
  • Can you provide json you're trying to decode? :) – martinezjc Sep 15 '20 at 05:54
  • Does this answer your question? [JSONDecodeError: Expecting value: line 1 column 1 (char 0)](https://stackoverflow.com/questions/16573332/jsondecodeerror-expecting-value-line-1-column-1-char-0) – Martin Zeitler Sep 15 '20 at 06:24
  • Have you checked Martin's link? If it doesn't help, could you provide the json you're trying to decode, as martinezjc suggested? Any more use case details or code will be useful as well. – Ksign Sep 15 '20 at 07:50
  • 2
    Yeah I did go through his link. The issue is I think with google colab while importing the file 'input.txt' Has anyone of you guys ecountered such error while using colab? I am trying to train the got2 model on the dataset 'input.txt'. The JSON part is happening on the colab's side – shivang Sep 15 '20 at 17:59

0 Answers0