reisarod commited on
Commit
70edc2e
·
verified ·
1 Parent(s): 02f06dd

Upload folder using huggingface_hub

Browse files
.gradio/certificate.pem ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ -----BEGIN CERTIFICATE-----
2
+ MIIFazCCA1OgAwIBAgIRAIIQz7DSQONZRGPgu2OCiwAwDQYJKoZIhvcNAQELBQAw
3
+ TzELMAkGA1UEBhMCVVMxKTAnBgNVBAoTIEludGVybmV0IFNlY3VyaXR5IFJlc2Vh
4
+ cmNoIEdyb3VwMRUwEwYDVQQDEwxJU1JHIFJvb3QgWDEwHhcNMTUwNjA0MTEwNDM4
5
+ WhcNMzUwNjA0MTEwNDM4WjBPMQswCQYDVQQGEwJVUzEpMCcGA1UEChMgSW50ZXJu
6
+ ZXQgU2VjdXJpdHkgUmVzZWFyY2ggR3JvdXAxFTATBgNVBAMTDElTUkcgUm9vdCBY
7
+ MTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAK3oJHP0FDfzm54rVygc
8
+ h77ct984kIxuPOZXoHj3dcKi/vVqbvYATyjb3miGbESTtrFj/RQSa78f0uoxmyF+
9
+ 0TM8ukj13Xnfs7j/EvEhmkvBioZxaUpmZmyPfjxwv60pIgbz5MDmgK7iS4+3mX6U
10
+ A5/TR5d8mUgjU+g4rk8Kb4Mu0UlXjIB0ttov0DiNewNwIRt18jA8+o+u3dpjq+sW
11
+ T8KOEUt+zwvo/7V3LvSye0rgTBIlDHCNAymg4VMk7BPZ7hm/ELNKjD+Jo2FR3qyH
12
+ B5T0Y3HsLuJvW5iB4YlcNHlsdu87kGJ55tukmi8mxdAQ4Q7e2RCOFvu396j3x+UC
13
+ B5iPNgiV5+I3lg02dZ77DnKxHZu8A/lJBdiB3QW0KtZB6awBdpUKD9jf1b0SHzUv
14
+ KBds0pjBqAlkd25HN7rOrFleaJ1/ctaJxQZBKT5ZPt0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 emyPxgcYxn/eR44/KJ4EBs+lVDR3veyJm+kXQ99b21/+jh5Xos1AnX5iItreGCc=
31
+ -----END CERTIFICATE-----
.gradio/flagged/dataset1.csv ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name,intensity,output,timestamp
2
+ Rei,0,"Hello, Rei",2024-11-17 02:29:18.557619
3
+ Rei Sarod,4,"Hello, Rei Sarod!!!!",2024-11-17 02:30:31.921196
4
+ Rei Sarod,12,"Hello, Rei Sarod!!!!!!!!!!!!",2024-11-17 02:39:13.260407
5
+ Rei Sarod,12,"Hello, Rei Sarod!!!!!!!!!!!!",2024-11-17 02:39:21.837807
6
+ Rei Sarod,12,"Hello, Rei Sarod!!!!!!!!!!!!",2024-11-17 02:39:29.253689
7
+ Rei Sarod,12,"Hello, Rei Sarod!!!!!!!!!!!!",2024-11-17 02:39:41.420515
8
+ Rei,0,"Hello, Rei",2024-11-17 03:19:09.849869
9
+ REi,0,"Hello, REi",2024-11-17 03:22:39.605772
10
+ REi,4,"Hello, REi!!!!",2024-11-17 03:22:42.937940
11
+ REi,4,"Hello, REi!!!!",2024-11-17 03:22:44.704268
.gradio/flagged/dataset2.csv ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ name,output,timestamp
2
+ Rei,Hello Rei!,2024-11-17 03:51:59.565018
3
+ Rei,Hello Rei!,2024-11-17 03:54:32.173563
README.md CHANGED
@@ -1,12 +1,6 @@
1
  ---
2
- title: Gradio
3
- emoji: 🔥
4
- colorFrom: gray
5
- colorTo: gray
6
  sdk: gradio
7
  sdk_version: 5.6.0
8
- app_file: app.py
9
- pinned: false
10
  ---
11
-
12
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
1
  ---
2
+ title: gradio
3
+ app_file: app.py
 
 
4
  sdk: gradio
5
  sdk_version: 5.6.0
 
 
6
  ---
 
 
api.py ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ from gradio_client import Client, file
2
+
3
+ client = Client("http://127.0.0.1:7860/")
4
+
5
+ client.predict(
6
+ name="Rei",
7
+ intensity=0,
8
+ api_name="/predict"
9
+ )
10
+
app.py ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+ def greet(name):
4
+ return "Hello " + name + "!"
5
+
6
+ demo = gr.Interface(fn=greet, inputs="textbox", outputs="textbox")
7
+
8
+ demo.launch(share=True) # Share your demo with just 1 extra parameter 🚀
9
+
10
+
11
+ from gradio_client import Client
12
+
13
+ client = Client("http://127.0.0.1:7860/")
14
+ result = client.predict(
15
+ name="Hello!!",
16
+ intensity=0,
17
+ api_name="/predict"
18
+ )
19
+ print(result)
audio_sample.wav ADDED
File without changes
client.py ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ from gradio_client import Client
2
+
3
+ client = Client("abidlabs/my-private-space", hf_token="")
diffusers ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ from diffusers import DiffusionPipeline
2
+
3
+ pipe = DiffusionPipeline.from_pretrained("SG161222/RealVisXL_V4.0")
4
+
5
+ prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"
6
+ image = pipe(prompt).images[0]
prueba.py ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ from gradio_client import Client, handle_file
2
+
3
+ client = Client("abidlabs/whisper")
4
+
5
+ client.predict(
6
+ audio=handle_file("audio_sample.wav")
7
+ )
text2image.py ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from gradio_client import Client, handle_file
2
+
3
+ client = Client("ysharma/Text_Behind_Image")
4
+ result = client.predict(
5
+ input_image=handle_file('https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png'),
6
+ text="Hello!!",
7
+ font_size=400,
8
+ color="White",
9
+ opacity=255,
10
+ x_position=50,
11
+ y_position=50,
12
+ thickness=0,
13
+ api_name="/add_text_to_image"
14
+ )
15
+ print(result)
trams ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ # pip install 'transformers>=4.39.1'
3
+ from transformers import AutoTokenizer, AutoModelForCausalLM
4
+
5
+ model_id = "CohereForAI/c4ai-command-r-plus-08-2024"
6
+ tokenizer = AutoTokenizer.from_pretrained(model_id)
7
+ model = AutoModelForCausalLM.from_pretrained(model_id)
8
+
9
+ # Format message with the command-r-plus-08-2024 chat template
10
+ messages = [{"role": "user", "content": "Hello, how are you?"}]
11
+ input_ids = tokenizer.apply_chat_template(messages, tokenize=True, add_generation_prompt=True, return_tensors="pt")
12
+ ## <BOS_TOKEN><|START_OF_TURN_TOKEN|><|USER_TOKEN|>Hello, how are you?<|END_OF_TURN_TOKEN|><|START_OF_TURN_TOKEN|><|CHATBOT_TOKEN|>
13
+
14
+ gen_tokens = model.generate(
15
+ input_ids,
16
+ max_new_tokens=100,
17
+ do_sample=True,
18
+ temperature=0.3,
19
+ )
20
+
21
+ gen_text = tokenizer.decode(gen_tokens[0])
22
+ print(gen_text)
transformes.py ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+ def greet(name):
4
+ return "Hello " + name + "!"
5
+
6
+ demo = gr.Interface(fn=greet, inputs="textbox", outputs="textbox")
7
+
8
+ demo.launch(share=True) # Share your demo with just 1 extra parameter 🚀