LeroyDyer commited on
Commit
55a51e7
1 Parent(s): 9d223c0

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +42 -37
README.md CHANGED
@@ -299,10 +299,52 @@ Sounds could also be identified and generated to thier base64 representations an
299
 
300
  ```
301
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
302
  ### Encoding/Decoding Images to Base64
303
 
 
304
  Code used to convert images to base 64:
305
 
 
306
  ```python
307
 
308
 
@@ -382,8 +424,6 @@ processed_dataset = dataset.map(process_images_func, batched=True)
382
 
383
  ### Converting sound to spectrographic images : Encoder Decoder !
384
 
385
- I did not Convert any sound files as of yet :
386
- I did use existing datasets :
387
 
388
  ```python
389
 
@@ -731,41 +771,6 @@ if __name__ == "__main__":
731
  ```
732
 
733
 
734
- ### Training :
735
-
736
- ```python
737
- alpaca_prompt = """You are the worlds archive of all knowledge , you perform tasks and answer all questions given without bias. your a friendly and helpfull artificial inteligence with a personality.
738
-
739
- Answer all questions Expertly and professionally ,determine the user intent and requirements ,Gather any required research to ensure accurate problem-solving for complex tasks.
740
- You are fully qualified to give any advice or solutions, your experience as a life coach and librarian and historian of sacred texts as well as scientific advisor,even as a software developer will enable you to answer these questions :
741
-
742
- ### Question:
743
- Here is an Spectrographic image in base64 format: describe this sound :
744
- image : {}
745
-
746
-
747
- ### Response:
748
- {}"""
749
-
750
-
751
- EOS_TOKEN = tokenizer.eos_token # Must add EOS_TOKEN
752
- def formatting_prompts_func(examples):
753
- instructions = examples["image_base64"]
754
- outputs = examples["text"]
755
- texts = []
756
- for instruction, output in zip(instructions, outputs):
757
- # Must add EOS_TOKEN, otherwise your generation will go on forever!
758
- text = alpaca_prompt.format(instruction, output) + EOS_TOKEN
759
- texts.append(text)
760
- return { "text" : texts, }
761
- pass
762
-
763
- from datasets import load_dataset
764
- dataset = load_dataset("LeroyDyer/soundsCaps-Spectrograms_to_Base64", split = "train[:150]")
765
 
766
- dataset = dataset.map(formatting_prompts_func, batched = True,)
767
-
768
-
769
- ```
770
 
771
 
 
299
 
300
  ```
301
 
302
+
303
+ ### Training :
304
+
305
+
306
+ ```python
307
+ alpaca_prompt = """You are the worlds archive of all knowledge , you perform tasks and answer all questions given without bias. your a friendly and helpfull artificial inteligence with a personality.
308
+
309
+ Answer all questions Expertly and professionally ,determine the user intent and requirements ,Gather any required research to ensure accurate problem-solving for complex tasks.
310
+ You are fully qualified to give any advice or solutions, your experience as a life coach and librarian and historian of sacred texts as well as scientific advisor,even as a software developer will enable you to answer these questions :
311
+
312
+ ### Question:
313
+ Here is an Spectrographic image in base64 format: describe this sound :
314
+ image : {}
315
+
316
+
317
+ ### Response:
318
+ {}"""
319
+
320
+
321
+ EOS_TOKEN = tokenizer.eos_token # Must add EOS_TOKEN
322
+ def formatting_prompts_func(examples):
323
+ instructions = examples["image_base64"]
324
+ outputs = examples["text"]
325
+ texts = []
326
+ for instruction, output in zip(instructions, outputs):
327
+ # Must add EOS_TOKEN, otherwise your generation will go on forever!
328
+ text = alpaca_prompt.format(instruction, output) + EOS_TOKEN
329
+ texts.append(text)
330
+ return { "text" : texts, }
331
+ pass
332
+
333
+ from datasets import load_dataset
334
+ dataset = load_dataset("LeroyDyer/soundsCaps-Spectrograms_to_Base64", split = "train[:150]")
335
+
336
+ dataset = dataset.map(formatting_prompts_func, batched = True,)
337
+
338
+
339
+ ```
340
+
341
+
342
  ### Encoding/Decoding Images to Base64
343
 
344
+
345
  Code used to convert images to base 64:
346
 
347
+
348
  ```python
349
 
350
 
 
424
 
425
  ### Converting sound to spectrographic images : Encoder Decoder !
426
 
 
 
427
 
428
  ```python
429
 
 
771
  ```
772
 
773
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
774
 
 
 
 
 
775
 
776