Commit
·
907930f
1
Parent(s):
c2d28a8
Update parquet files (step 1 of 121)
Browse filesThis view is limited to 50 files because it contains too many changes.
See raw diff
- spaces/0xAnders/ama-bot/app.py +0 -70
- spaces/101-5/gpt4free/g4f/.v1/gpt4free/gptworldAi/README.md +0 -25
- spaces/1gistliPinn/ChatGPT4/Examples/Ahmet Kanneci Gitar Metodu Pdf 16 [VERIFIED].md +0 -126
- spaces/1gistliPinn/ChatGPT4/Examples/Cinema 4d R20 Crack ((NEW)).md +0 -74
- spaces/1gistliPinn/ChatGPT4/Examples/Dream Aquarium Screensaver 1.52 Full Keygen HOT!.md +0 -121
- spaces/1phancelerku/anime-remove-background/Candy Crush Saga A Fun and Addictive Puzzle Game for Windows 7 PC.md +0 -120
- spaces/1phancelerku/anime-remove-background/Download Brawlhalla APK OBB and Experience the Thrill of Brawling.md +0 -75
- spaces/1phancelerku/anime-remove-background/Download Program AI The Essential Tool for Automating and Streamlining Your Business Processes.md +0 -113
- spaces/1phancelerku/anime-remove-background/Enjoy Pokmon GO with Mod Menu Download APK v0.273.1 and Explore New Options.md +0 -130
- spaces/1phancelerku/anime-remove-background/Enjoy Tsukis Odyssey MOD APK with No Ads and More Carrots.md +0 -117
- spaces/1toTree/lora_test/ppdiffusers/pipelines/paint_by_example/__init__.py +0 -26
- spaces/2023Liu2023/bingo/src/app/layout.tsx +0 -47
- spaces/801artistry/RVC801/infer/modules/train/extract/extract_f0_print.py +0 -298
- spaces/AI-Hobbyist/Hoyo-RVC/infer_pack/onnx_inference.py +0 -143
- spaces/AIFILMS/generate_human_motion/pyrender/pyrender/shader_program.py +0 -283
- spaces/AIGC-Audio/AudioGPT/text_to_speech/utils/audio/rnnoise.py +0 -48
- spaces/Abhilashvj/planogram-compliance/utils/flask_rest_api/README.md +0 -73
- spaces/AchyuthGamer/OpenGPT/g4f/Provider/deprecated/ChatgptLogin.py +0 -74
- spaces/AgentVerse/agentVerse/agentverse/agents/tasksolving_agent/role_assigner.py +0 -88
- spaces/AgentVerse/agentVerse/agentverse/environments/simulation_env/basic.py +0 -101
- spaces/AhmedMagdy7/My_paper_space/README.md +0 -13
- spaces/AkashKhamkar/Job_Search_Engine/skill_list.py +0 -3
- spaces/Akim/claudeAPI/webapi_claude.py +0 -60
- spaces/Alpaca233/SadTalker/predict.py +0 -192
- spaces/Amrrs/DragGan-Inversion/stylegan_human/pti/pti_models/e4e/stylegan2/op/fused_bias_act.cpp +0 -21
- spaces/Androidonnxfork/CivitAi-to-Diffusers/diffusers/src/diffusers/pipelines/stable_diffusion_safe/safety_checker.py +0 -109
- spaces/Andy1621/uniformer_image_detection/configs/faster_rcnn/faster_rcnn_r50_caffe_c4_1x_coco.py +0 -39
- spaces/Andy1621/uniformer_image_detection/mmdet/models/detectors/retinanet.py +0 -17
- spaces/Andy1621/uniformer_image_segmentation/configs/ocrnet/ocrnet_hr18s_512x1024_80k_cityscapes.py +0 -9
- spaces/Andy1621/uniformer_image_segmentation/configs/pspnet/pspnet_r50-d8_512x512_20k_voc12aug.py +0 -7
- spaces/AnishKumbhar/ChatBot/text-generation-webui-main/css/NotoSans/stylesheet.css +0 -166
- spaces/AnishKumbhar/ChatBot/text-generation-webui-main/js/main.js +0 -330
- spaces/Anonymous-123/ImageNet-Editing/editing_diffusion/guided_diffusion/README.md +0 -176
- spaces/Anonymous-sub/Rerender/ControlNet/annotator/uniformer/mmcv/ops/saconv.py +0 -145
- spaces/ArchitSharma/Digital-Photo-Color-Restoration/src/deoldify/__init__.py +0 -3
- spaces/Ash58947/Bot/Dockerfile +0 -21
- spaces/Ataturk-Chatbot/HuggingFaceChat/venv/lib/python3.11/site-packages/pkg_resources/_vendor/importlib_resources/_legacy.py +0 -121
- spaces/Awiny/Image2Paragraph/models/grit_src/third_party/CenterNet2/tests/structures/test_instances.py +0 -219
- spaces/Benson/text-generation/Examples/Carx Calle Pc Descargar Mediafre.md +0 -33
- spaces/Benson/text-generation/Examples/Descargar Cuentos De Los Hroes Gemelos Valientes (parcheado En Ingls) Iso Psp.md +0 -58
- spaces/Big-Web/MMSD/env/Lib/site-packages/botocore/regions.py +0 -830
- spaces/BigBoyBranding/README/README.md +0 -10
- spaces/CVPR/Dual-Key_Backdoor_Attacks/datagen/detectron2/tools/README.md +0 -45
- spaces/CVPR/Text2Human/Text2Human/models/archs/shape_attr_embedding_arch.py +0 -35
- spaces/CVPR/WALT/mmdet/models/roi_heads/mask_heads/feature_relay_head.py +0 -55
- spaces/CVPR/lama-example/bin/paper_runfiles/find_best_checkpoint.py +0 -54
- spaces/CVPR/lama-example/fetch_data/sampler.py +0 -39
- spaces/ChrisPreston/diff-svc_minato_aqua/utils/svc_utils.py +0 -141
- spaces/Cicooo/vits-uma-genshin-honkai/models.py +0 -534
- spaces/CofAI/chat/server/website.py +0 -58
spaces/0xAnders/ama-bot/app.py
DELETED
@@ -1,70 +0,0 @@
|
|
1 |
-
import gradio as gr
|
2 |
-
|
3 |
-
import git
|
4 |
-
|
5 |
-
git.Git().clone("https://github.com/Jesse-zj/bobo-test.git")
|
6 |
-
|
7 |
-
from llama_index import SimpleDirectoryReader, GPTListIndex, readers, GPTVectorStoreIndex, LLMPredictor, PromptHelper,ServiceContext
|
8 |
-
from llama_index import StorageContext, load_index_from_storage
|
9 |
-
from langchain import OpenAI
|
10 |
-
import sys
|
11 |
-
import os
|
12 |
-
from IPython.display import Markdown, display
|
13 |
-
|
14 |
-
openai_api_key = os.environ['OPENAI_API_KEY']
|
15 |
-
|
16 |
-
def construct_index(directory_path):
|
17 |
-
# set maximum input size
|
18 |
-
max_input_size = 4096
|
19 |
-
# set number of output tokens
|
20 |
-
num_outputs = 1000
|
21 |
-
# set maximum chunk overlap
|
22 |
-
max_chunk_overlap = 30
|
23 |
-
# set chunk size limit
|
24 |
-
chunk_size_limit = 600
|
25 |
-
|
26 |
-
# define LLM
|
27 |
-
llm_predictor = LLMPredictor(llm=OpenAI(temperature=0.5, model_name="text-davinci-003", max_tokens=num_outputs))
|
28 |
-
prompt_helper = PromptHelper(max_input_size, num_outputs, max_chunk_overlap, chunk_size_limit=chunk_size_limit)
|
29 |
-
|
30 |
-
documents = SimpleDirectoryReader(directory_path).load_data()
|
31 |
-
|
32 |
-
service_context = ServiceContext.from_defaults(llm_predictor=llm_predictor, prompt_helper=prompt_helper)
|
33 |
-
|
34 |
-
index = GPTVectorStoreIndex.from_documents(
|
35 |
-
documents, service_context=service_context
|
36 |
-
)
|
37 |
-
|
38 |
-
index.storage_context.persist('index.json')
|
39 |
-
|
40 |
-
return index
|
41 |
-
|
42 |
-
def ask_ai(query):
|
43 |
-
# set maximum input size
|
44 |
-
max_input_size = 4096
|
45 |
-
# set number of output tokens
|
46 |
-
num_outputs = 1000
|
47 |
-
# set maximum chunk overlap
|
48 |
-
max_chunk_overlap = 30
|
49 |
-
# set chunk size limit
|
50 |
-
chunk_size_limit = 600
|
51 |
-
|
52 |
-
# define LLM
|
53 |
-
llm_predictor = LLMPredictor(llm=OpenAI(temperature=0.5, model_name="text-davinci-003", max_tokens=num_outputs))
|
54 |
-
prompt_helper = PromptHelper(max_input_size, num_outputs, max_chunk_overlap, chunk_size_limit=chunk_size_limit)
|
55 |
-
|
56 |
-
service_context = ServiceContext.from_defaults(llm_predictor=llm_predictor, prompt_helper=prompt_helper)
|
57 |
-
# rebuild storage context
|
58 |
-
storage_context = StorageContext.from_defaults(persist_dir="index.json")
|
59 |
-
# load index
|
60 |
-
index = load_index_from_storage(storage_context, service_context=service_context)
|
61 |
-
|
62 |
-
query_engine = index.as_query_engine()
|
63 |
-
response = query_engine.query(query)
|
64 |
-
return str(response)
|
65 |
-
|
66 |
-
|
67 |
-
construct_index('bobo-test')
|
68 |
-
|
69 |
-
iface = gr.Interface(fn=ask_ai, inputs="textbox", outputs="text")
|
70 |
-
iface.launch()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/101-5/gpt4free/g4f/.v1/gpt4free/gptworldAi/README.md
DELETED
@@ -1,25 +0,0 @@
|
|
1 |
-
# gptworldAi
|
2 |
-
Written by [hp_mzx](https://github.com/hpsj).
|
3 |
-
|
4 |
-
## Examples:
|
5 |
-
### Completion:
|
6 |
-
```python
|
7 |
-
for chunk in gptworldAi.Completion.create("你是谁", "127.0.0.1:7890"):
|
8 |
-
print(chunk, end="", flush=True)
|
9 |
-
print()
|
10 |
-
```
|
11 |
-
|
12 |
-
### Chat Completion:
|
13 |
-
Support context
|
14 |
-
```python
|
15 |
-
message = []
|
16 |
-
while True:
|
17 |
-
prompt = input("请输入问题:")
|
18 |
-
message.append({"role": "user","content": prompt})
|
19 |
-
text = ""
|
20 |
-
for chunk in gptworldAi.ChatCompletion.create(message,'127.0.0.1:7890'):
|
21 |
-
text = text+chunk
|
22 |
-
print(chunk, end="", flush=True)
|
23 |
-
print()
|
24 |
-
message.append({"role": "assistant", "content": text})
|
25 |
-
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1gistliPinn/ChatGPT4/Examples/Ahmet Kanneci Gitar Metodu Pdf 16 [VERIFIED].md
DELETED
@@ -1,126 +0,0 @@
|
|
1 |
-
<br />
|
2 |
-
<h1>How to Learn Classical Guitar with Ahmet Kanneci Gitar Metodu Pdf 16</h1>
|
3 |
-
|
4 |
-
<p>Classical guitar is a beautiful and rewarding instrument that can enrich your life with music. However, learning classical guitar can also be challenging and frustrating if you don't have the right guidance and resources. That's why you need Ahmet Kanneci Gitar Metodu Pdf 16, a guitar method book that can teach you everything you need to know about classical guitar playing.</p>
|
5 |
-
|
6 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is a guitar method book written by Ahmet Kanneci, a Turkish classical guitar virtuoso and educator. He has studied and performed with some of the most famous guitarists in the world, such as Andrés Segovia, John Williams, Julian Bream, and Oscar Ghiglia. He has also taught many students and written several books on classical guitar.</p>
|
7 |
-
<h2>ahmet kanneci gitar metodu pdf 16</h2><br /><p><b><b>DOWNLOAD</b> ⇒ <a href="https://imgfil.com/2uy20p">https://imgfil.com/2uy20p</a></b></p><br /><br />
|
8 |
-
|
9 |
-
<p>In this article, we will explain what Ahmet Kanneci Gitar Metodu Pdf 16 is, what it contains, and how it can help you learn classical guitar. We will also give you some tips on how to use this book effectively and enjoyably.</p>
|
10 |
-
|
11 |
-
<h2>What is Ahmet Kanneci Gitar Metodu Pdf 16?</h2>
|
12 |
-
|
13 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is a guitar method book that covers various aspects of classical guitar playing, such as technique, theory, repertoire, and interpretation. It is divided into 16 chapters, each focusing on a specific topic or skill.</p>
|
14 |
-
|
15 |
-
<p>The book is written in Turkish, but it also includes musical notation and tablature for easy reference. It is suitable for beginners as well as intermediate and advanced players who want to improve their guitar skills.</p>
|
16 |
-
|
17 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is based on the author's extensive experience as a performer and teacher of classical guitar. He has used his own methods and insights to create a comprehensive and effective guitar curriculum that can help you achieve your musical goals.</p>
|
18 |
-
|
19 |
-
<h2>What does Ahmet Kanneci Gitar Metodu Pdf 16 contain?</h2>
|
20 |
-
|
21 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 contains a wealth of information and exercises that can help you master the classical guitar. Here are some of the topics that you can find in this book:</p>
|
22 |
-
<p></p>
|
23 |
-
|
24 |
-
<ul>
|
25 |
-
<li>Basic guitar anatomy and tuning</li>
|
26 |
-
<li>How to hold the guitar and position your hands</li>
|
27 |
-
<li>How to read musical notation and tablature</li>
|
28 |
-
<li>How to play scales, chords, arpeggios, and melodies</li>
|
29 |
-
<li>How to develop your right-hand and left-hand technique</li>
|
30 |
-
<li>How to practice effectively and efficiently</li>
|
31 |
-
<li>How to play various styles and genres of classical guitar music</li>
|
32 |
-
<li>How to interpret and express musical emotions</li>
|
33 |
-
<li>How to perform in front of an audience</li>
|
34 |
-
<li>How to avoid common mistakes and injuries</li>
|
35 |
-
</ul>
|
36 |
-
|
37 |
-
<p>The book also includes a selection of classical guitar pieces from different periods and regions, such as Renaissance, Baroque, Classical, Romantic, Modern, Turkish, Spanish, Latin American, etc. You can learn how to play these pieces with proper fingering, articulation, dynamics, phrasing, and ornamentation.</p>
|
38 |
-
|
39 |
-
<h2>How can Ahmet Kanneci Gitar Metodu Pdf 16 help you learn classical guitar?</h2>
|
40 |
-
|
41 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 can help you learn classical guitar in many ways. Here are some of the benefits that you can get from using this book:</p>
|
42 |
-
|
43 |
-
<ul>
|
44 |
-
<li>You can learn the fundamentals of classical guitar playing from a reputable and experienced guitarist.</li>
|
45 |
-
<li>You can improve your technical skills and musical knowledge through systematic and progressive exercises.</li>
|
46 |
-
<li>You can expand your repertoire and musical taste by playing diverse and beautiful pieces of classical guitar music.</li>
|
47 |
-
<li>You can enhance your musical expression and creativity by learning how to interpret and convey musical emotions.</li>
|
48 |
-
<li>You can boost your confidence and enjoyment by learning how to perform in front of an audience.</li>
|
49 |
-
</ul>
|
50 |
-
|
51 |
-
<h2>How to use Ahmet Kanneci Gitar Metodu Pdf 16 effectively and enjoyably?</h2>
|
52 |
-
|
53 |
-
<p>To use Ahmet Kanneci Gitar Metodu Pdf 16 effectively and enjoyably, you need to follow some guidelines and tips. Here are some of them:</p>
|
54 |
-
|
55 |
-
<ul>
|
56 |
-
<li>Make sure you have a good quality classical guitar that is comfortable and suitable for your size and level.</li>
|
57 |
-
<li>Make sure you have a good internet connection or a PDF reader to access the book online or offline.</li>
|
58 |
-
<li>Follow the instructions and suggestions given by the author in each chapter carefully and attentively.</li>
|
59 |
-
<li>Practice regularly and consistently, but not too much or too little. Aim for quality rather than quantity.</li>
|
60 |
-
<li>Review the previous chapters periodically to reinforce your learning and avoid forgetting.</li>
|
61 |
-
<li>Listen to recordings or watch videos of the pieces that you are learning or want to learn to get inspiration and guidance.</li>
|
62 |
-
<li>Seek feedback from other guitarists or teachers to improve your playing and correct your mistakes.</li>
|
63 |
-
<li>Have fun and enjoy the process of learning classical guitar with Ahmet Kanneci Gitar Metodu Pdf 16!</li>
|
64 |
-
</ul>
|
65 |
-
|
66 |
-
<h2>Conclusion</h2>
|
67 |
-
|
68 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is a comprehensive guide for classical guitar lovers who want to learn or improve their guitar skills. It covers various topics and skills related to classical guitar playing, such as technique, theory, repertoire, interpretation, performance, etc. It also includes a selection of classical guitar pieces from different periods and regions that you can play with pleasure and satisfaction.</p>
|
69 |
-
|
70 |
-
<p>If you are interested in Ahmet Kanneci Gitar Metodu Pdf 16, you can download it for free from the link below. You can also visit the author's website or social media pages to learn more about him and his work.</p>
|
71 |
-
|
72 |
-
<p>We hope this article has given you some useful information about Ahmet Kanneci Gitar Metodu Pdf 16. We wish you all the best in your classical guitar journey!</p>
|
73 |
-
<h2>Where can you download Ahmet Kanneci Gitar Metodu Pdf 16?</h2>
|
74 |
-
|
75 |
-
<p>If you want to download Ahmet Kanneci Gitar Metodu Pdf 16, you can do so for free from the link below. This is a verified and safe link that will direct you to the PDF file of the book. You can save it on your computer or mobile device and access it anytime you want.</p>
|
76 |
-
|
77 |
-
<p>Alternatively, you can also buy a hard copy of the book from online or offline bookstores. However, this might be more expensive and less convenient than downloading the PDF file.</p>
|
78 |
-
|
79 |
-
<p>Whichever option you choose, make sure you have a good quality classical guitar and a tuner to accompany your learning with Ahmet Kanneci Gitar Metodu Pdf 16.</p>
|
80 |
-
|
81 |
-
<h2>Who is Ahmet Kanneci and why should you trust him?</h2>
|
82 |
-
|
83 |
-
<p>Ahmet Kanneci is a Turkish classical guitar virtuoso and educator who has been playing and teaching classical guitar for over 40 years. He is widely regarded as one of the best classical guitarists in Turkey and in the world.</p>
|
84 |
-
|
85 |
-
<p>Ahmet Kanneci was born in Ankara in 1957. He started playing guitar at the age of 11 and soon showed great talent and passion for the instrument. He studied with some of the most renowned guitarists in the world, such as Andrés Segovia, John Williams, Julian Bream, and Oscar Ghiglia. He also graduated from Ankara State Conservatory and Middle East Technical University with degrees in music and architecture.</p>
|
86 |
-
|
87 |
-
<p>Ahmet Kanneci has performed in many countries and festivals, such as Spain, France, Italy, Germany, England, USA, Canada, Japan, China, etc. He has also recorded several albums and DVDs of classical guitar music. He has received numerous awards and honors for his musical achievements, such as the Presidential Culture and Art Grand Award, the State Artist Title, the Ankara Music Festival Honorary Award, etc.</p>
|
88 |
-
|
89 |
-
<p>Ahmet Kanneci has also taught many students and written several books on classical guitar. He is currently a professor at Hacettepe University Ankara State Conservatory. He is also the founder and president of the Classical Guitar Association of Turkey.</p>
|
90 |
-
|
91 |
-
<p>Ahmet Kanneci is a trustworthy and respected guitarist who can teach you how to play classical guitar with his book Ahmet Kanneci Gitar Metodu Pdf 16. You can learn from his experience, knowledge, and wisdom and become a better guitarist yourself.</p>
|
92 |
-
<h2>What are some reviews and testimonials of Ahmet Kanneci Gitar Metodu Pdf 16?</h2>
|
93 |
-
|
94 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 has received many positive reviews and testimonials from classical guitar enthusiasts who have used this book to learn or improve their guitar skills. Here are some of them:</p>
|
95 |
-
|
96 |
-
<blockquote>
|
97 |
-
<p>"I have been playing classical guitar for over 10 years and I have used many guitar method books, but none of them can compare to Ahmet Kanneci Gitar Metodu Pdf 16. This book is comprehensive, clear, and practical. It covers everything from basic to advanced topics and skills. It also has a great selection of pieces that are enjoyable and challenging to play. I have learned so much from this book and I highly recommend it to anyone who wants to learn classical guitar."</p>
|
98 |
-
<cite>- Ali, a classical guitar student from Istanbul</cite>
|
99 |
-
</blockquote>
|
100 |
-
|
101 |
-
<blockquote>
|
102 |
-
<p>"Ahmet Kanneci Gitar Metodu Pdf 16 is a masterpiece of classical guitar education. It is written by a master guitarist who knows how to teach and inspire his students. It is not just a book, but a journey that takes you from the fundamentals to the artistry of classical guitar playing. It is also a treasure that contains the essence of Turkish classical guitar music. I am grateful to Ahmet Kanneci for sharing his wisdom and passion with us through this book."</p>
|
103 |
-
<cite>- Emine, a classical guitar teacher from Ankara</cite>
|
104 |
-
</blockquote>
|
105 |
-
|
106 |
-
<blockquote>
|
107 |
-
<p>"I have always wanted to learn classical guitar, but I never had the time or the money to take lessons. Then I discovered Ahmet Kanneci Gitar Metodu Pdf 16 online and I decided to give it a try. I was amazed by how easy and fun it was to learn with this book. It has clear explanations, helpful diagrams, and engaging exercises. It also has beautiful pieces that make me feel like a professional guitarist. Thanks to Ahmet Kanneci Gitar Metodu Pdf 16, I have fulfilled my dream of playing classical guitar."</p>
|
108 |
-
<cite>- Murat, a classical guitar hobbyist from Izmir</cite>
|
109 |
-
</blockquote>
|
110 |
-
|
111 |
-
<h2>Conclusion</h2>
|
112 |
-
|
113 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is a comprehensive guide for classical guitar lovers who want to learn or improve their guitar skills. It covers various topics and skills related to classical guitar playing, such as technique, theory, repertoire, interpretation, performance, etc. It also includes a selection of classical guitar pieces from different periods and regions that you can play with pleasure and satisfaction.</p>
|
114 |
-
|
115 |
-
<p>If you are interested in Ahmet Kanneci Gitar Metodu Pdf 16, you can download it for free from the link below. You can also visit the author's website or social media pages to learn more about him and his work.</p>
|
116 |
-
|
117 |
-
<p>We hope this article has given you some useful information about Ahmet Kanneci Gitar Metodu Pdf 16. We wish you all the best in your classical guitar journey!</p>
|
118 |
-
<h2>Conclusion</h2>
|
119 |
-
|
120 |
-
<p>Ahmet Kanneci Gitar Metodu Pdf 16 is a comprehensive guide for classical guitar lovers who want to learn or improve their guitar skills. It covers various topics and skills related to classical guitar playing, such as technique, theory, repertoire, interpretation, performance, etc. It also includes a selection of classical guitar pieces from different periods and regions that you can play with pleasure and satisfaction.</p>
|
121 |
-
|
122 |
-
<p>If you are interested in Ahmet Kanneci Gitar Metodu Pdf 16, you can download it for free from the link below. You can also visit the author's website or social media pages to learn more about him and his work.</p>
|
123 |
-
|
124 |
-
<p>We hope this article has given you some useful information about Ahmet Kanneci Gitar Metodu Pdf 16. We wish you all the best in your classical guitar journey!</p> 3cee63e6c2<br />
|
125 |
-
<br />
|
126 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1gistliPinn/ChatGPT4/Examples/Cinema 4d R20 Crack ((NEW)).md
DELETED
@@ -1,74 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>Cinema 4d R20 Crack: A Powerful 3D Modeling and Animation Software</h1>
|
3 |
-
<p>If you are a 3D motion graphics artist, you might be one of the thousands of designers who use Cinema 4D regularly. Cinema 4D is a popular software for matte painters in film production, mainly because of its features in BodyPaint 3D. It is also a specialized and widely used application for 3D animation, as it is user-friendly, highly customizable and suitable for many purposes. It has been used for movies such as We Are the Strange, Polar Express, Open Season, Monster House, Spiderman 3 and recently Avengers by Paramount.</p>
|
4 |
-
<p>Cinema 4D supports creating amazing graphics quickly and easily. In addition to containing all the features of CINEMA 4D Prime, Visualize and Broadcast, CINEMA 4D Studio also offers advanced tools for character, hair, a physics engine and unlimited clients. The result is that Cinema 4D can handle any project with ease.</p>
|
5 |
-
<h2>Cinema 4d R20 Crack</h2><br /><p><b><b>Download File</b> ––– <a href="https://imgfil.com/2uxYMJ">https://imgfil.com/2uxYMJ</a></b></p><br /><br />
|
6 |
-
<h2>What's New in Cinema 4d R20 Crack?</h2>
|
7 |
-
<p>Cinema 4d R20 Crack is the latest version of this software, which brings many improvements and new features. Some of them are:</p>
|
8 |
-
<ul>
|
9 |
-
<li>New edges and remove parts with ease</li>
|
10 |
-
<li>New effects, shaders and shading options</li>
|
11 |
-
<li>New easy, fast and intuitive workflows</li>
|
12 |
-
<li>New powerful interactive knife tools</li>
|
13 |
-
<li>New real-world VFX workflows and tools</li>
|
14 |
-
<li>Othe bug fixes and improvements.</li>
|
15 |
-
</ul>
|
16 |
-
<h2>How to Download and Install Cinema 4d R20 Crack?</h2>
|
17 |
-
<p>If you want to try this software for free, you can download Cinema 4d R20 Crack from the internet. However, you should be careful about the source of the download, as some websites may contain viruses or malware that can harm your computer. Here are some steps to download and install Cinema 4d R20 Crack safely:</p>
|
18 |
-
<p></p>
|
19 |
-
<ol>
|
20 |
-
<li>Turn off your internet and antivirus connection.</li>
|
21 |
-
<li>Download Cinema 4d R20 Crack from a trusted website.</li>
|
22 |
-
<li>Extract the file that you downloaded using WinRAR or other software.</li>
|
23 |
-
<li>Install Cinema 4d R20 with installer use this key 14000000000-0000-0000-0000-0000-0000-0000.</li>
|
24 |
-
<li>When it is done put this file c4dp_20.0.26.xdl64 on C:\Program Files\MAXON\Cinema 4D R20\corelibs\.</li>
|
25 |
-
<li>Start Cinema 4d R20 and enjoy.</li>
|
26 |
-
</ol>
|
27 |
-
<h2>Conclusion</h2>
|
28 |
-
<p>Cinema 4d R20 Crack is a powerful software for 3D modeling and animation that can help you create stunning graphics and animations. It has many features and tools that make it easy and fast to use. You can download Cinema 4d R20 Crack from the internet for free, but you should be careful about the source and follow the instructions to install it properly. If you like this software, you should consider buying the original version from the official website to support the developers and get more benefits.</p>
|
29 |
-
<h2>Why Choose Cinema 4d R20 Crack?</h2>
|
30 |
-
<p>Cinema 4d R20 Crack is a great choice for anyone who wants to create stunning 3D graphics and animations without spending a lot of money. With Cinema 4d R20 Crack, you can access all the features and tools of the original software, such as:</p>
|
31 |
-
<ul>
|
32 |
-
<li>Advanced character tools to create realistic and dynamic characters</li>
|
33 |
-
<li>Hair tools to style, animate and render hair with ease</li>
|
34 |
-
<li>Physics engine to simulate real-world physics and collisions</li>
|
35 |
-
<li>MoGraph tools to create complex motion graphics and effects</li>
|
36 |
-
<li>BodyPaint 3D tools to paint directly on 3D models</li>
|
37 |
-
<li>Integration with popular video editing and compositing software</li>
|
38 |
-
<li>Unlimited network rendering clients to speed up your workflow</li>
|
39 |
-
</ul>
|
40 |
-
<p>Cinema 4d R20 Crack also has a user-friendly interface that can be customized according to your preferences. You can also use plugins and scripts to extend the functionality of Cinema 4d R20 Crack. Cinema 4d R20 Crack is compatible with Windows and Mac operating systems, and supports 64-bit technology for optimal performance.</p>
|
41 |
-
<h2>How to Use Cinema 4d R20 Crack?</h2>
|
42 |
-
<p>Cinema 4d R20 Crack is easy to use, even for beginners. You can start by creating a new project and choosing a preset or template that suits your needs. You can then use the various tools and menus to create and edit your 3D models, materials, lights, cameras, animations and more. You can also import and export files from other formats, such as OBJ, FBX, STL, DWG, etc.</p>
|
43 |
-
<p>Cinema 4d R20 Crack has a powerful rendering engine that allows you to preview your work in real-time or render it in high quality. You can also adjust the render settings to optimize your output for different purposes, such as web, print, video, etc. You can also use the network rendering feature to distribute your render tasks across multiple computers.</p>
|
44 |
-
<p>Cinema 4d R20 Crack also has a built-in help system that provides you with tutorials, tips and documentation. You can also access online resources, such as forums, blogs, videos and courses, to learn more about Cinema 4d R20 Crack and improve your skills.</p>
|
45 |
-
<h2>Cinema 4d R20 Crack: A Reliable Software for 3D Rendering</h2>
|
46 |
-
<p>Cinema 4d R20 Crack is a reliable software for 3D rendering that can help you create high-quality images and videos for your projects. Cinema 4D has a flexible and scalable rendering system that can adapt to your needs and preferences. You can choose between different render engines, such as Standard, Physical, ProRender, Hardware OpenGL and Sketch & Toon. You can also use various render settings, such as resolution, anti-aliasing, depth of field, motion blur, global illumination, ambient occlusion, caustics, subsurface scattering and more.</p>
|
47 |
-
<p>Cinema 4d R20 Crack also has a powerful network rendering feature that allows you to distribute your render tasks across multiple computers. You can use unlimited network rendering clients to speed up your workflow and save time. You can also use Team Render Server to manage your render jobs and monitor their progress. Cinema 4D also supports rendering in the background and in the viewport.</p>
|
48 |
-
<h2>Cinema 4d R20 Crack: A Creative Software for 3D Effects</h2>
|
49 |
-
<p>Cinema 4d R20 Crack is a creative software for 3D effects that can help you add realism and style to your animations. Cinema 4D has a rich library of effects, shaders and shading options that you can use to enhance your renders. You can also use various tools and modifiers to create complex motion graphics and effects.</p>
|
50 |
-
<p>Cinema 4d R20 Crack also has a powerful MoGraph toolset that allows you to create procedural animations with ease. You can use clones, effectors, fields, deformers and more to control your objects and generate dynamic animations. You can also use Voronoi Fracture, Volume Builder and Volume Mesher to create realistic destruction and explosion effects.</p>
|
51 |
-
<h2>Cinema 4d R20 Crack: A Flexible Software for 3D Sculpting</h2>
|
52 |
-
<p>Cinema 4d R20 Crack is a flexible software for 3D sculpting that can help you create organic and hard-surface models with ease. Cinema 4D has a powerful sculpting system that allows you to use brushes, masks, stamps, stencils and layers to sculpt your 3D objects. You can also use various tools and modifiers to smooth, pinch, inflate, flatten, erase and refine your sculpts.</p>
|
53 |
-
<p>Cinema 4d R20 Crack also has a feature called Sculpt to PoseMorph that allows you to create facial expressions and character animations from your sculpts. You can also use the Sculpt Symmetry option to sculpt symmetrically on any axis. Cinema 4D also supports importing and exporting sculpts from other formats, such as ZBrush, Mudbox, etc.</p>
|
54 |
-
<h2>Cinema 4d R20 Crack: A Fun Software for 3D Sketching</h2>
|
55 |
-
<p>Cinema 4d R20 Crack is a fun software for 3D sketching that can help you create artistic and cartoon-like images and videos. Cinema 4D has a feature called Sketch & Toon that allows you to apply different styles and effects to your renders. You can also use various tools and modifiers to sketch, outline, hatch, shade, crosshatch and paint your 3D objects.</p>
|
56 |
-
<p>Cinema 4d R20 Crack also has a feature called Cel Shader that allows you to create cel-shaded animations with ease. You can also use the Art Shader to create realistic pencil sketches, watercolors, oil paintings and more. Cinema 4D also supports importing and exporting sketches from other formats, such as Illustrator, Photoshop, etc.</p>
|
57 |
-
<h2>Cinema 4d R20 Crack: A User-Friendly Software for 3D Painting</h2>
|
58 |
-
<p>Cinema 4d R20 Crack is a user-friendly software for 3D painting that can help you create realistic and detailed textures for your models. Cinema 4D has a feature called BodyPaint 3D that allows you to paint directly on your 3D objects. You can also use various tools and modifiers to clone, smear, blur, erase and color your paints.</p>
|
59 |
-
<p>Cinema 4d R20 Crack also has a feature called UV Editing that allows you to adjust the mapping of your textures on your models. You can also use various tools and modifiers to relax, optimize, pin, weld and split your UVs. Cinema 4D also supports importing and exporting paints from other formats, such as Photoshop, Illustrator, etc.</p>
|
60 |
-
<h2>Cinema 4d R20 Crack: A Compatible Software for 3D Integration</h2>
|
61 |
-
<p>Cinema 4d R20 Crack is a compatible software for 3D integration that can help you work seamlessly with other applications and formats. Cinema 4D has a feature called Exchange that allows you to import and export files from other formats, such as OBJ, FBX, STL, DWG, Alembic, etc. You can also use various tools and modifiers to adjust the scale, rotation, position and animation of your imported or exported files.</p>
|
62 |
-
<p>Cinema 4d R20 Crack also has a feature called Integration that allows you to connect and work with other popular video editing and compositing software, such as After Effects, Premiere Pro, Final Cut Pro, Nuke, etc. You can also use various tools and modifiers to sync the cameras, lights, materials and animations between Cinema 4D and other software.</p>
|
63 |
-
<h2>Cinema 4d R20 Crack: A Secure Software for 3D Downloading</h2>
|
64 |
-
<p>Cinema 4d R20 Crack is a secure software for 3D downloading that can help you get the full version of Cinema 4D for free. Cinema 4D is a premium software that requires a license key to activate and use. However, you can download Cinema 4d R20 Crack from the internet and bypass the activation process.</p>
|
65 |
-
<p>Cinema 4d R20 Crack is a safe and reliable software that does not contain any viruses or malware that can harm your computer. You can also use Cinema 4d R20 Crack without any limitations or restrictions. You can access all the features and tools of Cinema 4D and enjoy creating amazing 3D graphics and animations.</p>
|
66 |
-
<h2>Cinema 4d R20 Crack: A Smart Software for 3D Learning</h2>
|
67 |
-
<p>Cinema 4d R20 Crack is a smart software for 3D learning that can help you improve your skills and knowledge in 3D modeling and animation. Cinema 4D is a software that has a lot of tutorials, tips and documentation that you can use to learn more about it. You can also access online resources, such as forums, blogs, videos and courses, to get more guidance and support.</p>
|
68 |
-
<p>Cinema 4d R20 Crack also has a feature called Help System that provides you with interactive help and context-sensitive information. You can also use the Content Browser to browse and access hundreds of presets, templates and objects that you can use for your projects. Cinema 4D also supports creating your own custom objects and saving them for later use.</p>
|
69 |
-
<h2>Cinema 4d R20 Crack: A Must-Have Software for 3D Enthusiasts</h2>
|
70 |
-
<p>Cinema 4d R20 Crack is a must-have software for 3D enthusiasts who want to create stunning and realistic 3D graphics and animations. Cinema 4D is a software that offers many features and tools that make it easy and fast to use. You can also download Cinema 4d R20 Crack from the internet for free and enjoy all the benefits of the original software.</p>
|
71 |
-
<p>Cinema 4d R20 Crack is a software that can help you with various aspects of 3D creation, such as modeling, animation, rendering, sculpting, painting, sketching, integration and more. You can also use Cinema 4d R20 Crack to learn more about 3D and improve your skills and knowledge. Cinema 4D is a software that is compatible, flexible, reliable, creative, user-friendly and fun to use.</p>
|
72 |
-
<p>If you are interested in Cinema 4d R20 Crack, you can download it from the link below and follow the instructions to install it properly. However, if you like this software, you should consider buying the original version from the official website to support the developers and get more benefits. Cinema 4D is a software that is worth investing in if you are serious about 3D.</p> 3cee63e6c2<br />
|
73 |
-
<br />
|
74 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1gistliPinn/ChatGPT4/Examples/Dream Aquarium Screensaver 1.52 Full Keygen HOT!.md
DELETED
@@ -1,121 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>Dream Aquarium Screensaver 1.52 Full Keygen: How to Get It and Why You Need It</h1>
|
3 |
-
|
4 |
-
<p>If you are looking for a stunning and realistic screensaver for your PC, you should definitely check out Dream Aquarium Screensaver 1.52 Full Keygen. This is a next-generation virtual aquarium that will mesmerize you with its amazing graphics, animations, and sounds. You can customize your own aquarium with dozens of different fish species, plants, backgrounds, and accessories. You can also interact with your fish, feed them, and watch them swim and behave in a natural way.</p>
|
5 |
-
<h2>dream aquarium screensaver 1.52 full keygen</h2><br /><p><b><b>Download File</b> ✓✓✓ <a href="https://imgfil.com/2uxYtN">https://imgfil.com/2uxYtN</a></b></p><br /><br />
|
6 |
-
|
7 |
-
<p>But how can you get Dream Aquarium Screensaver 1.52 Full Keygen for free? And why do you need a keygen to activate it? In this article, we will answer these questions and show you how to enjoy this awesome screensaver without paying a dime.</p>
|
8 |
-
|
9 |
-
<h2>What is Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
10 |
-
|
11 |
-
<p>Dream Aquarium Screensaver 1.52 is the latest version of the popular screensaver that was released in November 2012. It has many new features and improvements, such as:</p>
|
12 |
-
|
13 |
-
<ul>
|
14 |
-
<li>New fish species, including angelfish, clownfish, lionfish, and more.</li>
|
15 |
-
<li>New plants and decorations, such as coral reefs, rocks, bubbles, and more.</li>
|
16 |
-
<li>New backgrounds and themes, such as tropical islands, sunsets, underwater caves, and more.</li>
|
17 |
-
<li>New options and settings, such as water quality, lighting effects, fish behavior, and more.</li>
|
18 |
-
<li>Better performance and compatibility with Windows XP, Vista, 7, and 8.</li>
|
19 |
-
</ul>
|
20 |
-
|
21 |
-
<p>However, Dream Aquarium Screensaver 1.52 is not free. You have to pay $19.95 to get the full version that allows you to access all the features and options. If you download the trial version from the official website, you will only get a limited number of fish and backgrounds, and you will see a nag screen every time you run the screensaver.</p>
|
22 |
-
|
23 |
-
<p>That's why you need a keygen to activate Dream Aquarium Screensaver 1.52 Full Keygen. A keygen is a software that generates a serial number or a license key that you can use to register the screensaver and unlock all the features. By using a keygen, you can save money and enjoy Dream Aquarium Screensaver 1.52 Full Keygen for free.</p>
|
24 |
-
|
25 |
-
<h2>How to Get Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
26 |
-
|
27 |
-
<p>There are many websites that offer Dream Aquarium Screensaver 1.52 Full Keygen for free download. However, not all of them are reliable and safe. Some of them may contain viruses, malware, or spyware that can harm your PC or steal your personal information. Some of them may also provide fake or invalid keygens that won't work or will cause errors.</p>
|
28 |
-
<p></p>
|
29 |
-
|
30 |
-
<p>That's why we recommend you to download Dream Aquarium Screensaver 1.52 Full Keygen from our trusted link below. We have tested it and verified that it is clean and working. You can download it without any risk or hassle.</p>
|
31 |
-
|
32 |
-
<p>Here are the steps to get Dream Aquarium Screensaver 1.52 Full Keygen:</p>
|
33 |
-
|
34 |
-
<ol>
|
35 |
-
<li>Click on the download button below and save the file to your PC.</li>
|
36 |
-
<li>Extract the file using WinRAR or any other archive tool.</li>
|
37 |
-
<li>Run the setup file and follow the instructions to install Dream Aquarium Screensaver 1.52 on your PC.</li>
|
38 |
-
<li>Run the keygen file and click on the generate button to get a serial number.</li>
|
39 |
-
<li>Copy the serial number and paste it into the registration window of Dream Aquarium Screensaver 1.52.</li>
|
40 |
-
<li>Click on the register button and enjoy Dream Aquarium Screensaver 1.52 Full Keygen for free.</li>
|
41 |
-
</ol>
|
42 |
-
|
43 |
-
<p><a href="https://example.com/dream-aquarium-screensaver-152-full-keygen-download">Download Dream Aquarium Screensaver 1.52 Full Keygen Here</a></p>
|
44 |
-
|
45 |
-
<h2>Why You Need Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
46 |
-
|
47 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is not just a screensaver. It is a relaxing and entertaining experience that will make you feel like you are in a real aquarium. You can watch your fish swim around in a beautiful environment that changes according to the time of day and season. You can also listen to soothing sounds of water and bubbles that will calm your mind and mood.</p>
|
48 |
-
|
49 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is also a great way to decorate your PC and impress your friends and family. You can choose from hundreds of different combinations of fish, plants, backgrounds, and accessories to create your own unique aquarium. You can also take snapshots of your aquarium and share them online or use them as wallpapers.</p>
|
50 |
-
|
51 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is also a fun and educational tool that will teach you about different fish species and their habits. You can learn about their names, origins, sizes, colors, diets, lifespans, and more by clicking on them or reading their descriptions in the menu. You can also watch how they interact with each other and their environment in a realistic way.</p>
|
52 |
-
|
53 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is more than just a screensaver. It is a dream come true for anyone who loves aquariums and fish. By downloading it for free from our link below, you can enjoy this amazing screensaver without spending any money or compromising any quality.</p>
|
54 |
-
|
55 |
-
<p><a href="https://example.com/dream-aquarium-screensaver-152-full-keygen-download">Download Dream Aquarium Screensaver 1.52 Full Keygen Here</a></p>
|
56 |
-
<h2>What are the Benefits of Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
57 |
-
|
58 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is not only a beautiful and realistic screensaver, but also a beneficial one. Here are some of the benefits that you can get from using this screensaver:</p>
|
59 |
-
|
60 |
-
<ul>
|
61 |
-
<li>It can reduce your stress and anxiety by providing you with a relaxing and soothing environment. You can watch your fish swim peacefully and listen to the calming sounds of water and bubbles. You can also adjust the settings to suit your mood and preferences.</li>
|
62 |
-
<li>It can improve your productivity and creativity by stimulating your brain and senses. You can enjoy the stunning graphics and animations of the screensaver, which are based on real fish behavior and physics. You can also learn new facts and information about different fish species and their habitats.</li>
|
63 |
-
<li>It can enhance your PC's performance and security by saving your screen from burn-in and preventing unauthorized access. You can set a password to protect your PC from prying eyes when the screensaver is running. You can also save energy and resources by using the sleep mode option.</li>
|
64 |
-
</ul>
|
65 |
-
|
66 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that can benefit you in many ways. By downloading it for free from our link below, you can experience these benefits yourself.</p>
|
67 |
-
|
68 |
-
<h2>How to Customize Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
69 |
-
|
70 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that you can customize according to your own taste and style. You can create your own aquarium with hundreds of different combinations of fish, plants, backgrounds, and accessories. You can also change the options and settings to make your aquarium more realistic and attractive.</p>
|
71 |
-
|
72 |
-
<p>Here are some of the ways that you can customize Dream Aquarium Screensaver 1.52 Full Keygen:</p>
|
73 |
-
|
74 |
-
<ul>
|
75 |
-
<li>You can add or remove fish from your aquarium by clicking on the fish icon in the menu bar. You can choose from 16 different fish species, such as angelfish, clownfish, lionfish, and more. You can also adjust their number, size, color, speed, and personality.</li>
|
76 |
-
<li>You can decorate your aquarium by clicking on the plant icon in the menu bar. You can choose from various plants and decorations, such as coral reefs, rocks, bubbles, and more. You can also adjust their position, size, color, and density.</li>
|
77 |
-
<li>You can change the background of your aquarium by clicking on the background icon in the menu bar. You can choose from different backgrounds and themes, such as tropical islands, sunsets, underwater caves, and more. You can also adjust their brightness, contrast, saturation, and hue.</li>
|
78 |
-
<li>You can modify the options and settings of your aquarium by clicking on the options icon in the menu bar. You can change the water quality, lighting effects, fish behavior, sound effects, screen resolution, password protection, sleep mode, and more.</li>
|
79 |
-
</ul>
|
80 |
-
|
81 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that you can customize to make it your own. By downloading it for free from our link below, you can start customizing your aquarium today.</p>
|
82 |
-
<h2>How to Interact with Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
83 |
-
|
84 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is not just a passive screensaver. It is an interactive one that allows you to have fun and play with your fish and aquarium. You can do many things with Dream Aquarium Screensaver 1.52 Full Keygen, such as:</p>
|
85 |
-
|
86 |
-
<ul>
|
87 |
-
<li>You can feed your fish by clicking on the food icon in the menu bar. You can choose from different types of food, such as flakes, pellets, worms, and more. You can also adjust the amount and frequency of feeding.</li>
|
88 |
-
<li>You can touch your fish by moving your mouse over them. You can see them react to your touch in different ways, such as swimming away, following your cursor, or biting it. You can also tickle them by clicking on them.</li>
|
89 |
-
<li>You can zoom in and out of your aquarium by using the scroll wheel on your mouse. You can see your fish and plants in more detail and admire their beauty and realism.</li>
|
90 |
-
<li>You can take snapshots of your aquarium by clicking on the camera icon in the menu bar. You can save them to your PC or share them online with your friends and family.</li>
|
91 |
-
</ul>
|
92 |
-
|
93 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that you can interact with and have fun with. By downloading it for free from our link below, you can start interacting with your aquarium today.</p>
|
94 |
-
|
95 |
-
<h2>How to Update Dream Aquarium Screensaver 1.52 Full Keygen?</h2>
|
96 |
-
|
97 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that is constantly updated and improved by its developers. They are always adding new fish species, plants, backgrounds, and features to make the screensaver more realistic and enjoyable. You can get these updates for free by using the update option in the menu bar.</p>
|
98 |
-
|
99 |
-
<p>Here are some of the benefits of updating Dream Aquarium Screensaver 1.52 Full Keygen:</p>
|
100 |
-
|
101 |
-
<ul>
|
102 |
-
<li>You can get new fish species that are not available in the previous versions, such as seahorses, sharks, rays, and more.</li>
|
103 |
-
<li>You can get new plants and decorations that will make your aquarium more diverse and colorful, such as seaweed, anemones, starfish, and more.</li>
|
104 |
-
<li>You can get new backgrounds and themes that will change the mood and atmosphere of your aquarium, such as moonlight, stormy weather, shipwreck, and more.</li>
|
105 |
-
<li>You can get new options and settings that will enhance the performance and quality of your screensaver, such as anti-aliasing, motion blur, fish shadows, and more.</li>
|
106 |
-
</ul>
|
107 |
-
|
108 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that is always updated and improved to give you the best experience possible. By downloading it for free from our link below, you can get these updates automatically and enjoy the latest features of this screensaver.</p>
|
109 |
-
<h2>Conclusion</h2>
|
110 |
-
|
111 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that will transform your PC into a beautiful and realistic virtual aquarium. You can customize your own aquarium with hundreds of different combinations of fish, plants, backgrounds, and accessories. You can also interact with your fish, feed them, touch them, and watch them swim and behave in a natural way. You can also enjoy the stunning graphics and animations of the screensaver, which are based on real fish behavior and physics. You can also learn new facts and information about different fish species and their habitats.</p>
|
112 |
-
|
113 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is not free. You have to pay $19.95 to get the full version that allows you to access all the features and options. However, you can get it for free by using a keygen that will generate a serial number or a license key that you can use to register the screensaver and unlock all the features. You can download Dream Aquarium Screensaver 1.52 Full Keygen and the keygen from our trusted link below.</p>
|
114 |
-
|
115 |
-
<p>Dream Aquarium Screensaver 1.52 Full Keygen is a screensaver that will give you a relaxing and entertaining experience that will make you feel like you are in a real aquarium. It is also a beneficial screensaver that will reduce your stress and anxiety, improve your productivity and creativity, enhance your PC's performance and security, and teach you about different fish species and their habits. It is also a screensaver that is constantly updated and improved by its developers to give you the best experience possible.</p>
|
116 |
-
|
117 |
-
<p>If you love aquariums and fish, you should definitely download Dream Aquarium Screensaver 1.52 Full Keygen today and enjoy this amazing screensaver without paying a dime.</p>
|
118 |
-
|
119 |
-
<p><a href="https://example.com/dream-aquarium-screensaver-152-full-keygen-download">Download Dream Aquarium Screensaver 1.52 Full Keygen Here</a></p> 3cee63e6c2<br />
|
120 |
-
<br />
|
121 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1phancelerku/anime-remove-background/Candy Crush Saga A Fun and Addictive Puzzle Game for Windows 7 PC.md
DELETED
@@ -1,120 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>How to Download Candy Crush Saga on PC Windows 7</h1>
|
3 |
-
<p>Candy Crush Saga is one of the most popular and addictive puzzle games in the world. Millions of players love to switch and match candies in this sweet adventure. But did you know that you can also play Candy Crush Saga on your PC Windows 7? In this article, we will show you how to download and play Candy Crush Saga on PC Windows 7 using two different methods. We will also share some tips and tricks to help you enjoy the game even more.</p>
|
4 |
-
<h2>Introduction</h2>
|
5 |
-
<h3>What is Candy Crush Saga?</h3>
|
6 |
-
<p>Candy Crush Saga is a puzzle game developed by King. It was released in 2012 and has since become a global phenomenon. The game is simple but challenging. You have to match three or more candies of the same color to clear them from the board. You also have to complete various objectives, such as collecting ingredients, clearing jelly, or reaching a target score. The game has thousands of levels, each with different layouts, obstacles, and goals. You can also play with your friends and compete for the highest score.</p>
|
7 |
-
<h2>download candy crush saga pc windows 7</h2><br /><p><b><b>Download</b> ☆☆☆ <a href="https://jinyurl.com/2uNNUX">https://jinyurl.com/2uNNUX</a></b></p><br /><br />
|
8 |
-
<h3>Why play Candy Crush Saga on PC Windows 7?</h3>
|
9 |
-
<p>Playing Candy Crush Saga on your mobile device is fun, but playing it on your PC Windows 7 has some advantages. For example:</p>
|
10 |
-
<ul>
|
11 |
-
<li>You can enjoy the game on a bigger screen, which makes it easier to see the details and colors of the candies.</li>
|
12 |
-
<li>You can use your mouse or keyboard to control the game, which can be more comfortable and precise than using your fingers.</li>
|
13 |
-
<li>You can save your battery life and data usage by playing offline on your PC.</li>
|
14 |
-
<li>You can access more features and options, such as adjusting the sound and graphics settings, or using airplane mode to avoid ads.</li>
|
15 |
-
</ul>
|
16 |
-
<h2>How to download Candy Crush Saga on PC Windows 7</h2>
|
17 |
-
<h3>Method 1: Using Microsoft Store</h3>
|
18 |
-
<p>One of the easiest ways to download Candy Crush Saga on PC Windows 7 is to use the Microsoft Store app. This app allows you to download and install various games and apps from Microsoft. Here are the steps to follow:</p>
|
19 |
-
<h4>Step 1: Open Microsoft Store app</h4>
|
20 |
-
<p>To open the Microsoft Store app, you can either click on its icon on your taskbar or start menu, or type "Microsoft Store" in the search box and press enter.</p>
|
21 |
-
<h4>Step 2: Search for Candy Crush Saga</h4>
|
22 |
-
<p>Once you open the Microsoft Store app, you will see a search bar at the top right corner. Type "Candy Crush Saga" in the search bar and press enter. You will see a list of results related to your query.</p>
|
23 |
-
<h4>Step 3: Click on Get or Install button</h4>
|
24 |
-
<p>From the list of results, find the one that says "Candy Crush Saga" and has the logo of the game. Click on it to open its page. You will see a button that says "Get" or "Install" depending on whether you have already downloaded the game before or not. Click on that button to start the download process.</p>
|
25 |
-
<h4>Step 4: Launch the game and enjoy</h4>
|
26 |
-
<p>After the download is complete, you will see a button that says "Launch" or "Play" on the same page. Click on that button to open the game. You can also find the game icon on your start menu or desktop. Now you can enjoy playing Candy Crush Saga on your PC Windows 7.</p>
|
27 |
-
<h3>Method 2: Using BlueStacks emulator</h3>
|
28 |
-
<p>Another way to download Candy Crush Saga on PC Windows 7 is to use an emulator. An emulator is a software that allows you to run Android apps and games on your PC. One of the most popular and reliable emulators is BlueStacks. Here are the steps to follow:</p>
|
29 |
-
<h4>Step 1: Download and install BlueStacks on your PC</h4>
|
30 |
-
<p>To download BlueStacks, you can visit its official website at [bluestacks.com] and click on the "Download BlueStacks" button. You will get an installer file that you need to run on your PC. Follow the instructions on the screen to complete the installation process.</p>
|
31 |
-
<p>How to download candy crush saga on pc windows 7<br />
|
32 |
-
Candy crush saga for pc windows 7 free download<br />
|
33 |
-
Download candy crush saga for windows 7 laptop<br />
|
34 |
-
Candy crush saga download for pc windows 7 offline<br />
|
35 |
-
Candy crush saga game download for pc windows 7 32 bit<br />
|
36 |
-
Candy crush saga pc windows 7 download full version<br />
|
37 |
-
Download candy crush saga for windows 7 without bluestacks<br />
|
38 |
-
Candy crush saga download for pc windows 7 softonic<br />
|
39 |
-
Download candy crush saga for windows 7 ultimate<br />
|
40 |
-
Candy crush saga game free download for pc windows 7 filehippo<br />
|
41 |
-
Download candy crush saga for pc windows 7 professional<br />
|
42 |
-
Candy crush saga download for windows 7 microsoft store<br />
|
43 |
-
Download candy crush saga for pc windows 7 online<br />
|
44 |
-
Candy crush saga game download for pc windows 7 64 bit<br />
|
45 |
-
Candy crush saga pc windows 7 download apk<br />
|
46 |
-
Download candy crush saga for windows 7 using bluestacks<br />
|
47 |
-
Candy crush saga download for pc windows 7 uptodown<br />
|
48 |
-
Download candy crush saga for windows 7 home premium<br />
|
49 |
-
Candy crush saga game download for pc windows 7 with keyboard<br />
|
50 |
-
Candy crush saga pc windows 7 download crack<br />
|
51 |
-
Download candy crush saga for windows 7 emulator<br />
|
52 |
-
Candy crush saga download for pc windows 7 nox player<br />
|
53 |
-
Download candy crush saga for windows 7 enterprise<br />
|
54 |
-
Candy crush saga game download for pc windows 7 latest version<br />
|
55 |
-
Candy crush saga pc windows 7 download mod<br />
|
56 |
-
Download candy crush saga for windows 7 from king.com<br />
|
57 |
-
Candy crush saga download for pc windows 7 memu play<br />
|
58 |
-
Download candy crush saga for windows 7 starter<br />
|
59 |
-
Candy crush saga game download for pc windows 7 old version<br />
|
60 |
-
Candy crush saga pc windows 7 download hack<br />
|
61 |
-
Download candy crush saga for windows 7 by king<br />
|
62 |
-
Candy crush saga download for pc windows 7 ldplayer<br />
|
63 |
-
Download candy crush saga for windows 7 basic<br />
|
64 |
-
Candy crush saga game download for pc windows 7 update<br />
|
65 |
-
Candy crush saga pc windows 7 download cheats<br />
|
66 |
-
Download candy crush saga for windows 7 from microsoft.com<br />
|
67 |
-
Candy crush saga download for pc windows 7 gameloop<br />
|
68 |
-
Download candy crush saga for windows 7 pro<br />
|
69 |
-
Candy crush saga game download for pc windows 7 install<br />
|
70 |
-
Candy crush saga pc windows 7 download patch<br />
|
71 |
-
Download candy crush saga for windows 7 original<br />
|
72 |
-
Candy crush saga download for pc windows 7 koplayer<br />
|
73 |
-
Download candy crush saga for windows 7 iso file<br />
|
74 |
-
Candy crush saga game download for pc windows 7 play store<br />
|
75 |
-
Candy crush saga pc windows 7 download keygen<br />
|
76 |
-
Download candy crush saga for windows 7 from google play store</p>
|
77 |
-
<h4>Step 2: Launch BlueStacks and sign in with Google account</h4>
|
78 |
-
<p>After installing BlueStacks, you need to launch it and sign in with your Google account. This will allow you to access the Google Play Store and download apps and games. If you don't have a Google account, you can create one for free.</p>
|
79 |
-
<h4>Step 3: Search for Candy Crush Saga in the Play Store</h4>
|
80 |
-
<p>Once you sign in with your Google account, you will see the Play Store icon on the home screen of BlueStacks. Click on it to open the Play Store app. Then, type "Candy Crush Saga" in the search bar and press enter. You will see a list of results related to your query.</p>
|
81 |
-
<h4>Step 4: Click on Install button and wait for the game to download</h4>
|
82 |
-
<p>From the list of results, find the one that says "Candy Crush Saga" and has the logo of the game. Click on it to open its page. You will see a button that says "Install". Click on that button to start the download process.</p>
|
83 |
-
<h4>Step 5: Open the game and start playing</h4>
|
84 |
-
<p>After the download is complete, you will see a button that says "Open" on the same page. Click on that button to launch the game. You can also find the game icon on the home screen of BlueStacks. Now you can enjoy playing Candy Crush Saga on your PC Windows 7.</p>
|
85 |
-
<h2>Tips and tricks to play Candy Crush Saga on PC Windows 7</h2>
|
86 |
-
<p>Candy Crush Saga is a fun and addictive game, but it can also be challenging and frustrating at times. To help you overcome the difficulties and have more fun, here are some tips and tricks to play Candy Crush Saga on PC Windows 7:</p>
|
87 |
-
<h3>Use boosters wisely</h3>
|
88 |
-
<p>Boosters are special items that can help you clear levels faster and easier. You can get boosters by completing quests, watching ads, or buying them with real money. However, boosters are limited and should be used wisely. Don't waste them on easy levels or when you are close to winning. Save them for hard levels or when you are stuck.</p>
|
89 |
-
<h3>Plan your moves ahead</h3>
|
90 |
-
<p>Candy Crush Saga is a game of strategy, not luck. You have a limited number of moves to complete each level, so you need to plan your moves ahead. Don't just match candies randomly, but look for patterns and opportunities to create special candies or clear obstacles. Try to think one or two steps ahead and anticipate the consequences of your moves.</p>
|
91 |
-
<h3>Match special candies for more effects</h3>
|
92 |
-
<p>Special candies are candies that have extra effects when matched with other candies. They are created by matching four or more candies of the same color in different shapes. For example, matching four candies in a row creates a striped candy, which clears a whole row or column when matched. Matching five candies in a row creates a color bomb, which clears all candies of one color when matched. Matching five candies in an L or T shape creates a wrapped candy, which explodes twice when matched. Matching two special candies together creates even more powerful effects, such as clearing multiple rows and columns, or clearing all candies of two colors.</p>
|
93 |
-
<h3>Check the daily rewards and challenges</h3>
|
94 |
-
<p>Candy Crush Saga offers various rewards and challenges for its players every day. You can get free boosters by spinning the daily booster wheel, or by completing the daily quests. You can also participate in the daily challenges, such as the sugar track, the candy order, or the episode race. These challenges can give you extra rewards, such as gold bars, lives, or boosters. To access the daily rewards and challenges, you can click on the icons on the left side of the game screen.</p>
|
95 |
-
<h2>Conclusion</h2>
|
96 |
-
<p>Candy Crush Saga is a fun and addictive puzzle game that you can play on your PC Windows 7. You can download and install the game using either the Microsoft Store app or the BlueStacks emulator. You can also use some tips and tricks to play the game better, such as using boosters wisely, planning your moves ahead, matching special candies for more effects, and checking the daily rewards and challenges. We hope this article has helped you learn how to download Candy Crush Saga on PC Windows 7 and enjoy the game more. Happy crushing!</p>
|
97 |
-
<h2>FAQs</h2>
|
98 |
-
<p>Here are some frequently asked questions about Candy Crush Saga on PC Windows 7:</p>
|
99 |
-
<ul>
|
100 |
-
<li><b>Q: How can I sync my progress between my PC and my mobile device?</b></li>
|
101 |
-
<li>A: You can sync your progress by connecting your game to your Facebook account. This will allow you to access your game data across different devices and platforms. To connect your game to your Facebook account, you can click on the "Connect" button on the game screen.</li>
|
102 |
-
<li><b>Q: How can I get more lives in Candy Crush Saga?</b></li>
|
103 |
-
<li>A: You have five lives in Candy Crush Saga, which are replenished over time. If you run out of lives, you can either wait for them to refill, or ask your friends for help. You can also buy more lives with gold bars, which are the premium currency of the game. To buy more lives with gold bars, you can click on the "+" button next to your lives counter.</li>
|
104 |
-
<li><b>Q: How can I play Candy Crush Saga offline on PC Windows 7?</b></li>
|
105 |
-
<li>A: You can play Candy Crush Saga offline on PC Windows 7 by using the airplane mode feature. This feature allows you to play the game without any internet connection or ads. However, you will not be able to access some features, such as the daily rewards and challenges, or sync your progress with your Facebook account. To activate the airplane mode feature, you can click on the settings icon on the game screen and toggle the airplane mode option.</li>
|
106 |
-
<li><b>Q: How can I update Candy Crush Saga on PC Windows 7?</b></li>
|
107 |
-
<li>A: You can update Candy Crush Saga on PC Windows 7 by following these steps:</li>
|
108 |
-
<ul>
|
109 |
-
<li>If you downloaded the game from the Microsoft Store app, you can open the app and click on the "Downloads and updates" option on the left side menu. Then, you can click on the "Get updates" button and wait for the app to check for updates. If there is an update available for Candy Crush Saga, it will be downloaded and installed automatically.</li>
|
110 |
-
<li>If you downloaded the game from BlueStacks emulator, you can open the emulator and click on the "My games" tab on the home screen. Then, you can find Candy Crush Saga from your list of games and click on it to open its page. If there is an update available for Candy Crush Saga, it will be shown on the top right corner of the page. You can click on it to download and install the update.</li>
|
111 |
-
</ul>
|
112 |
-
<li><b>Q: How can I uninstall Candy Crush Saga from PC Windows 7?</b></li>
|
113 |
-
<li>A: You can uninstall Candy Crush Saga from PC Windows 7 by following these steps:</li>
|
114 |
-
<ul>
|
115 |
-
<li>If you downloaded the game from the Microsoft Store app, you can open the app and click on the "Library" option on the left side menu. Then, you can find Candy Crush Saga from your list of games and apps and right-click on it. You will see an option that says "Uninstall". Click on it and confirm your choice to remove the game from your PC.</li>
|
116 |
-
<li>If you downloaded the game from BlueStacks emulator, you can open the emulator and click on the "My games" tab on the home screen. Then, you can find Candy Crush Saga from your list of games and right-click on it. You will see an option that says "Uninstall". Click on it and confirm your choice to remove the game from your PC.</li>
|
117 |
-
</ul>
|
118 |
-
</ul></p> 401be4b1e0<br />
|
119 |
-
<br />
|
120 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1phancelerku/anime-remove-background/Download Brawlhalla APK OBB and Experience the Thrill of Brawling.md
DELETED
@@ -1,75 +0,0 @@
|
|
1 |
-
<br />
|
2 |
-
<h1>Brawlhalla Mod Apk + Obb: Everything You Need to Know</h1>
|
3 |
-
<p>Brawlhalla is a free-to-play platform fighting game that supports cross-play across various devices, including PC, consoles, and mobile. It features over 50 unique characters, each with their own weapons and skills, and various game modes that cater to different play styles and preferences. Brawlhalla has been praised for its accessibility, diversity, and frequent updates that keep the game fresh and exciting.</p>
|
4 |
-
<p>However, some players may want to enhance their gaming experience by using mod apk and obb files. These are modified versions of the original game files that can unlock premium content, provide unlimited resources, or add new features to the game. In this article, we will explain how to download and install brawlhalla mod apk + obb on your Android device, as well as the benefits and risks of using them.</p>
|
5 |
-
<h2>brawlhalla mod apk + obb</h2><br /><p><b><b>Download File</b> ☆ <a href="https://jinyurl.com/2uNQ3w">https://jinyurl.com/2uNQ3w</a></b></p><br /><br />
|
6 |
-
<h2>How to Download and Install Brawlhalla Mod Apk + Obb on Android Devices</h2>
|
7 |
-
<p>If you want to try out brawlhalla mod apk + obb on your Android device, you will need to follow these steps:</p>
|
8 |
-
<h3>Step 1: Enable unknown sources on your device</h3>
|
9 |
-
<p>Since brawlhalla mod apk + obb are not available on the official Google Play Store, you will need to enable unknown sources on your device to allow the installation of third-party apps. To do this, go to Settings > Security > Unknown Sources and toggle it on.</p>
|
10 |
-
<h3>Step 2: Download the mod apk and obb files from a trusted source</h3>
|
11 |
-
<p>Next, you will need to download the mod apk and obb files from a trusted source. There are many websites that offer brawlhalla mod apk + obb files, but not all of them are safe and reliable. You should always check the reviews, ratings, and comments of other users before downloading any file. Some of the best sources for brawlhalla mod apk + obb files are , , and . You can also use a VPN service or an antivirus app to protect your device from malware.</p>
|
12 |
-
<h3>Step 3: Install the mod apk file and copy the obb file to the Android/obb folder</h3>
|
13 |
-
<p>After downloading the mod apk and obb files, you will need to install the mod apk file by tapping on it and following the instructions. Then, you will need to copy the obb file to the Android/obb folder on your device's internal storage. If you don't have an obb folder, you can create one manually.</p>
|
14 |
-
<h3>Step 4: Launch the game and enjoy the mod features</h3>
|
15 |
-
<p>Finally, you can launch the game from your app drawer or home screen and enjoy the mod features. Depending on the mod apk and obb files you downloaded, you may have access to unlimited money, unlocked characters, enhanced gameplay features, and more. You can check the mod description or the settings menu to see what features are available.</p>
|
16 |
-
<h2>What are the Benefits and Risks of Using Brawlhalla Mod Apk + Obb</h2>
|
17 |
-
<p>Using brawlhalla mod apk + obb can have both benefits and risks for your gaming experience. Here are some of them:</p>
|
18 |
-
<p>brawlhalla mod apk + obb latest version download<br />
|
19 |
-
brawlhalla mod apk + obb unlimited money and coins<br />
|
20 |
-
brawlhalla mod apk + obb offline mode<br />
|
21 |
-
brawlhalla mod apk + obb all characters unlocked<br />
|
22 |
-
brawlhalla mod apk + obb no root required<br />
|
23 |
-
brawlhalla mod apk + obb free skins and weapons<br />
|
24 |
-
brawlhalla mod apk + obb cross-play support<br />
|
25 |
-
brawlhalla mod apk + obb hack cheats<br />
|
26 |
-
brawlhalla mod apk + obb android 11 compatible<br />
|
27 |
-
brawlhalla mod apk + obb direct link<br />
|
28 |
-
brawlhalla mod apk + obb high graphics quality<br />
|
29 |
-
brawlhalla mod apk + obb easy installation guide<br />
|
30 |
-
brawlhalla mod apk + obb fast and secure download<br />
|
31 |
-
brawlhalla mod apk + obb updated features and bug fixes<br />
|
32 |
-
brawlhalla mod apk + obb online multiplayer mode<br />
|
33 |
-
brawlhalla mod apk + obb best action fighting game<br />
|
34 |
-
brawlhalla mod apk + obb epic battles and tournaments<br />
|
35 |
-
brawlhalla mod apk + obb custom game modes and maps<br />
|
36 |
-
brawlhalla mod apk + obb fun and addictive gameplay<br />
|
37 |
-
brawlhalla mod apk + obb low storage space required<br />
|
38 |
-
brawlhalla mod apk + obb smooth and responsive controls<br />
|
39 |
-
brawlhalla mod apk + obb awesome sound effects and music<br />
|
40 |
-
brawlhalla mod apk + obb legendary heroes and villains<br />
|
41 |
-
brawlhalla mod apk + obb weekly events and rewards<br />
|
42 |
-
brawlhalla mod apk + obb global leaderboards and rankings<br />
|
43 |
-
brawlhalla mod apk + obb friendly and active community<br />
|
44 |
-
brawlhalla mod apk + obb regular updates and improvements<br />
|
45 |
-
brawlhalla mod apk + obb no ads or in-app purchases<br />
|
46 |
-
brawlhalla mod apk + obb full version unlocked<br />
|
47 |
-
brawlhalla mod apk + obb 100% working and tested</p>
|
48 |
-
<h3>Benefits</h3>
|
49 |
-
<ul>
|
50 |
-
<li>Unlimited money: You can buy anything you want in the game without worrying about running out of coins or gems. You can also upgrade your characters and weapons to the max level and enjoy the best performance.</li>
|
51 |
-
<li>Unlocked characters: You can play with any character you like, even the ones that are normally locked behind a paywall or a season pass. You can also try out different combinations of weapons and skills and find your favorite play style.</li>
|
52 |
-
<li>Enhanced gameplay features: You can enjoy some extra features that are not available in the original game, such as custom skins, maps, modes, effects, etc. You can also tweak some settings to improve your graphics, sound, or performance.</li>
|
53 |
-
</ul>
|
54 |
-
<h3>Risks</h3>
|
55 |
-
<ul>
|
56 |
-
<li>Malware infection: Some brawlhalla mod apk + obb files may contain malicious code that can harm your device or steal your personal information. You should always scan the files before installing them and avoid downloading from unknown or suspicious sources.</li>
|
57 |
-
<li>Account ban: Using brawlhalla mod apk + obb may violate the terms of service of the game and result in your account being banned or suspended. You may lose all your progress and purchases and be unable to play the game online with other players. You should always use a secondary account or a guest account when using brawlhalla mod apk + obb.</li>
|
58 |
-
<li>Game instability: Using brawlhalla mod apk + obb may cause some bugs, glitches, crashes, or errors in the game. You may experience lag, freezes, or crashes during gameplay or loading screens. You may also encounter compatibility issues with the latest updates or patches of the game. You should always backup your original game files and data before using brawlhalla mod apk + obb.</li>
|
59 |
-
</ul>
|
60 |
-
<h2>Conclusion</h2>
|
61 |
-
<p>Brawlhalla is a fun and addictive platform fighting game that you can play for free on various devices. However, if you want to spice up your gaming experience, you can try using brawlhalla mod apk + obb files that can unlock premium content, provide unlimited resources, or add new features to the game. However, you should also be aware of the risks involved in using brawlhalla mod apk + obb files, such as malware infection, account ban, or game instability. You should always download from trusted sources, scan the files before installing them, use a secondary or guest account, backup your original game files and data, and update your mod apk and obb files regularly.</p>
|
62 |
-
<p>We hope this article has helped you understand everything you need to know about brawlhalla mod apk + obb files. If you have any questions or comments, feel free to leave them below. And if you enjoyed this article, don't forget to share it with your friends and fellow gamers. Happy brawling!</p>
|
63 |
-
<h2>FAQs</h2>
|
64 |
-
<h3>What are some of the best brawlhalla mod apk + obb sources?</h3>
|
65 |
-
<p>Some of the best sources for brawlhalla mod apk + obb files are , , and . These websites offer safe and reliable downloads of various brawlhalla mod apk + obb files that can suit your preferences and needs.</p>
|
66 |
-
<h3>How can I update brawlhalla mod apk + obb to the latest version?</h3>
|
67 |
-
<p>To update brawlhalla mod apk + obb to the latest version, you will need to download the latest version of the mod apk and obb files from the same source you downloaded them from before. Then, you will need to uninstall the previous version of the mod apk file and install the new one. You will also need to replace the old obb file with the new one in the Android/obb folder. Alternatively, you can use an app like that can automatically update your mod apk and obb files for you.</p>
|
68 |
-
<h3>Can I play brawlhalla mod apk + obb online with other players?</h3>
|
69 |
-
<p>Yes, you can play brawlhalla mod apk + obb online with other players who are using the same version of the mod apk and obb files as you. However, you may not be able to play with players who are using the original game files or different versions of the mod apk and obb files. You may also face the risk of getting banned or suspended by the game developers if they detect that you are using mod apk and obb files.</p>
|
70 |
-
<h3>Is brawlhalla mod apk + obb compatible with iOS devices?</h3>
|
71 |
-
<p>No, brawlhalla mod apk + obb files are not compatible with iOS devices. Apk and obb files are only designed for Android devices and cannot be installed or run on iOS devices. If you want to play brawlhalla on your iOS device, you will need to download the official game from the App Store.</p>
|
72 |
-
<h3>Is brawlhalla mod apk + obb legal and safe?</h3>
|
73 |
-
<p>Brawlhalla mod apk + obb files are not legal and safe in most cases. Mod apk and obb files are considered as a form of piracy and hacking, which can violate the intellectual property rights of the game developers and publishers. Using mod apk and obb files can also expose your device to malware, viruses, or spyware, which can damage your device or compromise your privacy. Moreover, using mod apk and obb files can result in your account being banned or suspended by the game developers if they detect any abnormal activity or behavior. Therefore, we do not recommend using brawlhalla mod apk + obb files unless you are fully aware of the consequences and risks involved.</p> 401be4b1e0<br />
|
74 |
-
<br />
|
75 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1phancelerku/anime-remove-background/Download Program AI The Essential Tool for Automating and Streamlining Your Business Processes.md
DELETED
@@ -1,113 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>How to Download Program AI for Free</h1>
|
3 |
-
<p>Program AI is a term that refers to artificial intelligence software or tools that can create, edit, or produce various types of content, such as vector graphics, sketches, drawings, and artwork. Program AI can help you with various tasks and projects, such as logo design, icon creation, text styling, and more. In this article, you will learn what program AI is, what are its benefits and types, how to choose the right program AI for your needs, how to download program AI for free, how to use it effectively, what are its challenges and limitations, and what are the future trends and developments in program AI.</p>
|
4 |
-
<h2>What is Program AI?</h2>
|
5 |
-
<p>Program AI is a subset of artificial intelligence that focuses on creating or manipulating content using algorithms and data. Program AI can generate content from scratch or enhance existing content with various features and effects. Program AI can also learn from feedback and improve its performance over time. Some examples of program AI are:</p>
|
6 |
-
<h2>download program ai</h2><br /><p><b><b>Download Zip</b> ✫ <a href="https://jinyurl.com/2uNNJP">https://jinyurl.com/2uNNJP</a></b></p><br /><br />
|
7 |
-
<ul>
|
8 |
-
<li>Illustrator: A software that allows you to create vector graphics, logos, icons, sketches, typography, and complex illustrations.</li>
|
9 |
-
<li>WizCase: A tool that helps you download various software for free, such as Illustrator, Photoshop, InDesign, Premiere Pro, and more.</li>
|
10 |
-
<li>Adobe Illustrator CC: A cloud-based version of Illustrator that offers more features and updates than the standalone version.</li>
|
11 |
-
</ul>
|
12 |
-
<h2>Benefits of Program AI</h2>
|
13 |
-
<p>Program AI can offer many benefits for users who want to create or edit content. Some of the benefits are:</p>
|
14 |
-
<ul>
|
15 |
-
<li>Creativity: Program AI can help you unleash your creativity by providing you with multiple tools and options for creating stunning designs from your imagination.</li>
|
16 |
-
<li>Efficiency: Program AI can help you save time and effort by automating or simplifying some tasks that would otherwise require manual work or skills.</li>
|
17 |
-
<li>Quality: Program AI can help you improve the quality of your content by adding details, effects, filters, layers, gradients, colors, and more.</li>
|
18 |
-
<li>Versatility: Program AI can help you create content that can be used at any size and in any project, from online graphics to billboards, bus wraps, and beyond.</li>
|
19 |
-
<li>Learning: Program AI can help you learn new skills or techniques by providing you with tutorials, tips, feedback, and examples.</li>
|
20 |
-
</ul>
|
21 |
-
<h2>Types of Program AI</h2>
|
22 |
-
<p>Program AI can be classified into different types based on the type of content they create or edit. Some of the types are:</p>
|
23 |
-
<ul>
|
24 |
-
<li>Vector-based: These are programs that create or edit content using vectors, which are mathematical expressions that define points, lines, curves, shapes, colors, etc. Vector-based programs can scale up or down without losing quality or resolution. Examples are Illustrator and WizCase.</li>
|
25 |
-
<li>Raster-based: These are programs that create or edit content using pixels, which are small dots that make up an image. Raster-based programs have a fixed resolution and can lose quality or clarity when scaled up or down. Examples are Photoshop and GIMP.</li>
|
26 |
-
<li>Text-based: These are programs that create or edit content using text, such as fonts, styles, sizes, alignments, etc. Text-based programs can be used for creating logos, headlines, captions, labels, etc. Examples are InDesign and Word.</li>
|
27 |
-
<li>Audio-based: These are programs that create or edit content using sound, such as music, voice, effects, etc. Audio-based programs can be used for creating podcasts, songs, jingles, soundtracks, etc. Examples are Audacity and GarageBand.</li>
|
28 |
-
<li>Video-based: These are programs that create or edit content using video, such as clips, frames, transitions, filters, etc. Video-based programs can be used for creating movies, animations, commercials, presentations, etc. Examples are Premiere Pro and iMovie.</li>
|
29 |
-
</ul>
|
30 |
-
<h2>How to Choose the Right Program AI for Your Needs</h2>
|
31 |
-
<p>Choosing the right program AI for your needs can be challenging, as there are many factors to consider. Some of the factors are:</p>
|
32 |
-
<ul>
|
33 |
-
<li>Purpose: What do you want to create or edit with program AI? Depending on your goal, you may need a different type of program AI that suits your content and project.</li>
|
34 |
-
<li>Budget: How much are you willing to spend on program AI? Depending on your budget, you may need to look for free or affordable options that offer the features and functions you need.</li>
|
35 |
-
<li>Skill level: How proficient are you with program AI? Depending on your skill level, you may need a program AI that is easy to use or offers more advanced options and controls.</li>
|
36 |
-
<li>Compatibility: How compatible is the program AI with your device and system? Depending on your device and system, you may need a program AI that works well with your hardware and software specifications.</li>
|
37 |
-
<li>Support: How much support does the program AI offer? Depending on your needs, you may need a program AI that provides tutorials, guides, customer service, updates, etc.</li>
|
38 |
-
</ul>
|
39 |
-
<h2>How to Download Program AI for Free</h2>
|
40 |
-
<p>If you want to download program AI for free, you have several options. One option is to get a free trial of a program AI that offers a limited time or functionality for testing purposes. Another option is to use a tool that helps you download various software for free, such as WizCase. Here are some examples of how to download program AI for free:</p>
|
41 |
-
<h3>Adobe Illustrator</h3>
|
42 |
-
<p>Adobe Illustrator is one of the most popular vector-based program AI that allows you to create logos, icons, drawings, typography, and illustrations. You can download Adobe Illustrator for free by following these steps:</p>
|
43 |
-
<ol>
|
44 |
-
<li>Go to the Adobe Illustrator website and click on "Free Trial".</li>
|
45 |
-
<li>Sign in with your Adobe ID or create one if you don't have one.</li>
|
46 |
-
<li>Select your plan and payment method. You won't be charged until the end of the trial period.</li>
|
47 |
-
<li>Download and install the Adobe Creative Cloud app on your device.</li>
|
48 |
-
<li>Launch the app and sign in with your Adobe ID.</li>
|
49 |
-
<li>Select Illustrator from the list of apps and click on "Install".</li>
|
50 |
-
<li>Wait for the installation to complete and then launch Illustrator from the app or your desktop.</li>
|
51 |
-
</ol>
|
52 |
-
<h3>WizCase</h3>
|
53 |
-
<p>WizCase is a tool that helps you download various software for free, such as Illustrator, Photoshop, InDesign, such as vector graphics, sketches, drawings, and artwork. However, program AI also has some challenges and limitations, such as accuracy, ethics, creativity, and dependency. Therefore, you should use program AI wisely and responsibly, and always keep learning and improving your own skills and abilities. If you want to download program AI for free, you can try a free trial of a program AI software, such as Adobe Illustrator, or use a tool that helps you download various software for free, such as WizCase. You can also use program AI effectively by following some tips and best practices, such as knowing your purpose, exploring the features, experimenting with different settings, providing feedback, and using your creativity. Program AI is constantly evolving and improving, and you can expect to see more types, categories, integration, collaboration, personalization, customization, intelligence, and autonomy of program AI in the future.</p>
|
54 |
-
<h3>FAQs</h3>
|
55 |
-
<p>Here are some frequently asked questions about program AI and their answers:</p>
|
56 |
-
<ul>
|
57 |
-
<li>Q: What is the difference between program AI and graphic design? A: Program AI is a term that refers to artificial intelligence software or tools that can create or edit various types of content. Graphic design is a discipline that involves creating visual content using elements such as typography, images, colors, shapes, etc. Program AI can be used for graphic design purposes, but graphic design also requires human creativity, skills, and knowledge.</li>
|
58 |
-
<li>Q: What are some examples of program AI tools or software? A: Some examples of program AI tools or software are Illustrator, WizCase, Adobe Illustrator CC, Photoshop, GIMP, InDesign, Word, Audacity, GarageBand, Premiere Pro, iMovie, etc.</li>
|
59 |
-
<li>Q: How can I learn more about program AI? A: You can learn more about program AI by reading articles or blogs on the topic, watching videos or tutorials on how to use program AI tools or software, taking online courses or workshops on program AI, joining online communities or forums on program AI, or asking experts or professionals on program AI.</li>
|
60 |
-
<li>Q: What are some of the advantages and disadvantages of using program AI? A: Some of the advantages of using program AI are creativity, efficiency, quality, versatility, and learning. Some of the disadvantages of using program AI are accuracy, ethics, creativity, and dependency.</li>
|
61 |
-
<li>Q: What are some of the future trends and developments in program AI? A: Some of the future trends and developments in program AI are more types and categories of program AI, more integration and collaboration of program AI, more personalization and customization of program AI, more intelligence and autonomy of program AI.</li>
|
62 |
-
</ul></p>
|
63 |
-
<p>download program ai free trial<br />
|
64 |
-
download program ai for windows<br />
|
65 |
-
download program ai for mac<br />
|
66 |
-
download program ai online<br />
|
67 |
-
download program ai full version<br />
|
68 |
-
download program ai crack<br />
|
69 |
-
download program ai serial key<br />
|
70 |
-
download program ai portable<br />
|
71 |
-
download program ai tutorial<br />
|
72 |
-
download program ai software<br />
|
73 |
-
download program ai app<br />
|
74 |
-
download program ai design<br />
|
75 |
-
download program ai vector<br />
|
76 |
-
download program ai logo<br />
|
77 |
-
download program ai icon<br />
|
78 |
-
download program ai sketch<br />
|
79 |
-
download program ai drawing<br />
|
80 |
-
download program ai illustration<br />
|
81 |
-
download program ai art<br />
|
82 |
-
download program ai graphics<br />
|
83 |
-
download program ai tools<br />
|
84 |
-
download program ai brushes<br />
|
85 |
-
download program ai effects<br />
|
86 |
-
download program ai filters<br />
|
87 |
-
download program ai layers<br />
|
88 |
-
download program ai color<br />
|
89 |
-
download program ai gradient<br />
|
90 |
-
download program ai text<br />
|
91 |
-
download program ai font<br />
|
92 |
-
download program ai typography<br />
|
93 |
-
download program ai style<br />
|
94 |
-
download program ai template<br />
|
95 |
-
download program ai project<br />
|
96 |
-
download program adobe illustrator<br />
|
97 |
-
download adobe illustrator free trial<br />
|
98 |
-
download adobe illustrator for windows<br />
|
99 |
-
download adobe illustrator for mac<br />
|
100 |
-
download adobe illustrator online<br />
|
101 |
-
download adobe illustrator full version<br />
|
102 |
-
download adobe illustrator crack<br />
|
103 |
-
download adobe illustrator serial key<br />
|
104 |
-
download adobe illustrator portable<br />
|
105 |
-
download adobe illustrator tutorial<br />
|
106 |
-
download adobe illustrator software<br />
|
107 |
-
download adobe illustrator app <br />
|
108 |
-
download adobe illustrator design <br />
|
109 |
-
download adobe illustrator vector <br />
|
110 |
-
download adobe illustrator logo <br />
|
111 |
-
download adobe illustrator icon</p> 401be4b1e0<br />
|
112 |
-
<br />
|
113 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1phancelerku/anime-remove-background/Enjoy Pokmon GO with Mod Menu Download APK v0.273.1 and Explore New Options.md
DELETED
@@ -1,130 +0,0 @@
|
|
1 |
-
<br />
|
2 |
-
<h1>Download Pokemon Go Mod Menu: A Guide for Beginners</h1>
|
3 |
-
<p>Pokemon Go is one of the most popular mobile games in the world, with millions of players catching, battling, and trading Pokemon in real-world locations. The game uses augmented reality technology to overlay virtual creatures on your smartphone screen as you explore your surroundings. Pokemon Go is fun, addictive, and rewarding, but it can also be challenging, frustrating, and time-consuming.</p>
|
4 |
-
<p>That's why some players use a mod menu to enhance their gameplay experience. A mod menu is a tool that allows you to access various cheats and hacks in the game, such as joystick, teleport, speed, radar, and more. With a mod menu, you can catch more Pokemon, level up faster, win more battles, and enjoy the game in new ways.</p>
|
5 |
-
<h2>download pokemon go mod menu</h2><br /><p><b><b>Download</b> >>>>> <a href="https://jinyurl.com/2uNRTm">https://jinyurl.com/2uNRTm</a></b></p><br /><br />
|
6 |
-
<p>However, using a mod menu is not without risks. You could get banned or detected by the game developers, lose your account or data, or face legal consequences. You also need to be careful about where you download the mod menu from, as some sources may contain viruses or malware that could harm your device.</p>
|
7 |
-
<p>In this article, we will show you how to download Pokemon Go mod menu safely and legally, what features it offers, how to use it effectively, and what are the risks and benefits of playing with it. By the end of this article, you will be able to decide whether you want to try out the mod menu or stick to the regular gameplay.</p>
|
8 |
-
<h2>Features of Pokemon Go Mod Menu</h2>
|
9 |
-
<p>A mod menu is a software that modifies the game code to enable certain cheats and hacks. There are many different mod menus available for Pokemon Go, but they usually have some common features. Here are some of the most popular ones:</p>
|
10 |
-
<ul>
|
11 |
-
<li><strong>Joystick</strong>: This feature allows you to control your movement on the map with a virtual joystick on your screen. You can walk, run, or fly anywhere you want without actually moving in real life. This is useful for catching Pokemon that are far away or in inaccessible places.</li>
|
12 |
-
<li><strong>Teleport</strong>: This feature allows you to instantly jump to any location on the map by entering the coordinates or selecting a preset destination. You can teleport to places where rare or legendary Pokemon spawn, or where there are many PokeStops or Gyms.</li>
|
13 |
-
<li><strong>Speed</strong>: This feature allows you to adjust your speed on the map. You can increase or decrease your speed as you wish, depending on how fast you want to travel or hatch eggs.</li>
|
14 |
-
<li><strong>Radar</strong>: This feature allows you to see all the Pokemon that are nearby on your screen. You can also filter by type, rarity, IVs, CPs, or distance. You can tap on any Pokemon to see its exact location and catch it easily.</li>
|
15 |
-
<li><strong>And more</strong>: Depending on the mod menu you use, you may also have access to other features such as enhanced throw, encounter/inventory IVs, caught preview, tap to walk/teleport, 100 IV feed, nearby radar, etc.</li>
|
16 |
-
</ul>
|
17 |
-
<p>Each feature has its own advantages and disadvantages. For example, using joystick or teleport can help you catch more Pokemon in less time, but it can also make the game less realistic and immersive. Using speed can help you hatch eggs faster, but it can also drain your battery quicker. Using radar can help you find rare or specific Pokemon easier but it can also spoil the surprise and challenge of discovering them yourself.</p>
|
18 |
-
<h2>Tips and Tricks for Using Pokemon Go Mod Menu</h2>
|
19 |
-
<p>If you decide to use a mod menu for Pokemon Go, you need to be careful and smart about how you use it. Here are some tips and tricks to help you avoid getting banned or detected, optimize your gameplay, and have more fun with the mod menu:</p>
|
20 |
-
<ul>
|
21 |
-
<li><strong>Use a VPN</strong>: A VPN (virtual private network) is a service that encrypts and hides your online activity from your internet service provider, the game developers, and other third parties. Using a VPN can help you avoid getting tracked or traced by your IP address, which could lead to a ban or suspension. A VPN can also help you access geo-restricted content or servers in other regions. However, not all VPNs are reliable or safe, so make sure you choose a reputable one that has good reviews and ratings.</li>
|
22 |
-
<li><strong>Use a fake GPS</strong>: A fake GPS is an app that spoofs your location on your device. Using a fake GPS can help you trick the game into thinking that you are in a different place than you actually are. This can help you catch Pokemon that are not available in your area, or participate in events or raids that are happening elsewhere. However, using a fake GPS can also cause errors or glitches in the game, such as rubber-banding, soft bans, or shadow bans. To avoid these issues, make sure you use a fake GPS that is compatible with your device and the game, and that you do not change your location too frequently or drastically.</li>
|
23 |
-
<li><strong>Use a secondary account</strong>: A secondary account is an alternative account that you use for testing or experimenting with the mod menu. Using a secondary account can help you protect your main account from getting banned or suspended, as well as preserve your progress and achievements. You can use a secondary account to try out different features of the mod menu, see how they work, and find out what are the best settings and options for your gameplay style. However, using a secondary account can also be risky, as you may lose access to it at any time, or get caught by the game developers. To avoid these problems, make sure you do not link your secondary account to your main account, or use any personal information that could identify you.</li>
|
24 |
-
<li><strong>Use moderation</strong>: Moderation is the key to using the mod menu safely and responsibly. Using moderation means that you do not abuse or overuse the features of the mod menu, that you do not interfere with other players' gameplay experience, and that you do not violate the terms of service or the spirit of the game. Using moderation can help you avoid getting banned or detected, as well as maintain a balance between challenge and enjoyment. You can use moderation by limiting the frequency and intensity of your mod menu usage, by following the cooldown periods and distances between actions, and by respecting the rules and etiquette of the game community.</li>
|
25 |
-
</ul>
|
26 |
-
<h2>Risks and Benefits of Playing Pokemon Go with Mod Menu</h2>
|
27 |
-
<p>Playing Pokemon Go with mod menu can have both positive and negative effects on your health, social life, and ethics. Here are some of the risks and benefits of using mod menu for Pokemon Go:</p>
|
28 |
-
<table>
|
29 |
-
<tr>
|
30 |
-
<th>Risks</th>
|
31 |
-
<th>Benefits</th>
|
32 |
-
</tr>
|
33 |
-
<tr>
|
34 |
-
<td>- You could get banned or suspended from the game, losing your account, data, and progress.</td>
|
35 |
-
<td>- You could catch more Pokemon, level up faster, win more battles, and complete more tasks.</td>
|
36 |
-
</tr>
|
37 |
-
<tr>
|
38 |
-
<td>- You could get infected by viruses or malware from downloading unsafe or unverified mod menus.</td>
|
39 |
-
<td>- You could access more features and options that are not available in the regular gameplay.</td>
|
40 |
-
</tr>
|
41 |
-
<tr>
|
42 |
-
<td>- You could damage your device or battery by running too many apps or processes at once.</td>
|
43 |
-
<td>- You could save time and energy by playing from anywhere without moving.</td>
|
44 |
-
</tr>
|
45 |
-
<tr>
|
46 |
-
<td>- You could harm your physical or mental health by playing too much or too intensely.</td>
|
47 |
-
<td>- You could improve your mood or relieve stress by playing for fun or relaxation.</td>
|
48 |
-
</tr>
|
49 |
-
<tr>
|
50 |
-
<td>- You could lose interest or satisfaction in the game by making it too easy or boring.</td>
|
51 |
-
<td>- You could discover new places or experiences by exploring different locations or modes.</td>
|
52 |
-
</tr>
|
53 |
-
<tr>
|
54 |
-
<td>- You could ruin the gameplay experience for other players by cheating or hacking.</td>
|
55 |
-
<td>- You could make new friends or join communities by interacting with other players.</td>
|
56 |
-
</tr>
|
57 |
-
<tr>
|
58 |
-
<td>- You could break the law or ethics by violating the terms of service or intellectual property rights.</td>
|
59 |
-
<td>- You could express your creativity or personality by customizing your gameplay style.</td>
|
60 |
-
</tr>
|
61 |
-
</table>
|
62 |
-
<h2>Conclusion</h2>
|
63 |
-
<p>Pokemon Go is a great game that can bring you joy, adventure, and connection. However, it can also be challenging, frustrating, and time-consuming. That's why some players use a mod menu to enhance their gameplay experience. A mod menu is a tool that allows you to access various cheats and hacks in the game, such as joystick, teleport, speed, radar, and more. With a mod menu, you can catch more Pokemon, level up faster, win more battles, and enjoy the game in new ways.</p>
|
64 |
-
<p>However, using a mod menu is not without risks. You could get banned or detected by the game developers, lose your account or data, or face legal consequences. You also need to be careful about where you download the mod menu from, as some sources may contain viruses or malware that could harm your device. You also need to be responsible and respectful when using the mod menu, as you could affect your own or other players' gameplay experience.</p>
|
65 |
-
<p>download pokemod for pokemon go<br />
|
66 |
-
how to get pokemod atlas features for pokemon go<br />
|
67 |
-
pokemod performance mode for pokemon go<br />
|
68 |
-
pokemod shiny scanner for pokemon go<br />
|
69 |
-
pokemod spawn booster for pokemon go<br />
|
70 |
-
pokemod vpgp2+ for pokemon go<br />
|
71 |
-
pokemod quest tweaks for pokemon go<br />
|
72 |
-
pokemod swift gift for pokemon go<br />
|
73 |
-
pokemod tap to teleport for pokemon go<br />
|
74 |
-
pokemod instant catch for pokemon go<br />
|
75 |
-
pokemod inventory tweaks for pokemon go<br />
|
76 |
-
pokemod incognito mode for pokemon go<br />
|
77 |
-
pokemod headshot for pokemon go<br />
|
78 |
-
pokemod skip encounter intro for pokemon go<br />
|
79 |
-
pokemod team rocket blastoff 2 reloaded for pokemon go<br />
|
80 |
-
pokemod replace names with ivs in encounters for pokemon go<br />
|
81 |
-
pokemod tamagotchi for pokemon go<br />
|
82 |
-
pokemod block non-shiny encounters for pokemon go<br />
|
83 |
-
pokemod show encounter iv for pokemon go<br />
|
84 |
-
pokemod team leader zero hit ko for pokemon go<br />
|
85 |
-
pokemod instant spin for pokemon go<br />
|
86 |
-
pokemod pinap master for pokemon go<br />
|
87 |
-
pokemod shows ivs in inventory for pokemon go<br />
|
88 |
-
pokemod transfer on catch for pokemon go<br />
|
89 |
-
pokemod raid pack for pokemon go<br />
|
90 |
-
download no modded pokemon go with pokemod features<br />
|
91 |
-
how to install pokemod on android devices<br />
|
92 |
-
how to attach pokemod to pokemon go app<br />
|
93 |
-
how to use pokemod toggles in pokemon go game<br />
|
94 |
-
how to update pokemod for latest version of pokemon go<br />
|
95 |
-
download free trial of pokemod pro features for pokemon go<br />
|
96 |
-
how to buy pokemod pro subscription for pokemon go<br />
|
97 |
-
how to cancel pokemod pro subscription for pokemon go<br />
|
98 |
-
how to contact pokemod support team for pokemon go issues<br />
|
99 |
-
how to join pokemod discord community for pokemon go tips and tricks<br />
|
100 |
-
download best settings for pokemod in pokemon go game play <br />
|
101 |
-
how to avoid bans and warnings using pokemod in pokemon go game play <br />
|
102 |
-
how to spoof location using gps joystick and pokemod in pokemon go game play <br />
|
103 |
-
how to catch rare and shiny pokemon using pokemod in pokemon go game play <br />
|
104 |
-
how to complete quests and challenges using pokemod in pokemon go game play <br />
|
105 |
-
how to win battles and raids using pokemod in pokemon go game play <br />
|
106 |
-
how to level up and earn xp using pokemod in pokemon go game play <br />
|
107 |
-
how to manage inventory and items using pokemod in pokemon go game play <br />
|
108 |
-
how to interact with buddy and friends using pokemod in pokemon go game play <br />
|
109 |
-
download reviews and testimonials of pokemod users in pokemon go game play <br />
|
110 |
-
download comparison of pokemod and other mod menus in pokemon go game play <br />
|
111 |
-
download pros and cons of using pokemod in pokemon go game play</p>
|
112 |
-
<p>In this article, we showed you how to download Pokemon Go mod menu safely and legally, what features it offers, how to use it effectively, and what are the risks and benefits of playing with it. We hope that this article helped you make an informed decision about whether you want to try out the mod menu or stick to the regular gameplay.</p>
|
113 |
-
<p>If you want to download Pokemon Go mod menu, you can follow the link below and follow the instructions. However, we advise you to use it at your own risk and discretion, and to follow the tips and tricks we provided to avoid getting banned or detected. We also recommend you to use the mod menu moderately and responsibly, and to enjoy the game as it was intended to be played.</p>
|
114 |
-
<p>Are you ready to download Pokemon Go mod menu and catch 'em all? Click here to get started!</p>
|
115 |
-
<h2>FAQs</h2>
|
116 |
-
<p>Here are some of the most frequently asked questions about Pokemon Go mod menu:</p>
|
117 |
-
<ol>
|
118 |
-
<li><strong>What is Pokemon Go mod menu?</strong></li>
|
119 |
-
<p>Pokemon Go mod menu is a tool that allows you to access various cheats and hacks in the game, such as joystick, teleport, speed, radar, and more.</p>
|
120 |
-
<li><strong>How do I download Pokemon Go mod menu?</strong></li>
|
121 |
-
<p>You can download Pokemon Go mod menu from a reliable and verified source that provides a safe and legal download link. You can follow the link below and follow the instructions.</p>
|
122 |
-
<li><strong>Is Pokemon Go mod menu safe and legal?</strong></li>
|
123 |
-
<p>Pokemon Go mod menu is not officially endorsed or supported by the game developers or publishers. Using it may violate the terms of service or intellectual property rights of the game. It may also expose your device or account to viruses or malware. Therefore, using Pokemon Go mod menu is not safe or legal, and you do it at your own risk and discretion.</p>
|
124 |
-
<li><strong>How do I use Pokemon Go mod menu?</strong></li>
|
125 |
-
<p>You can use Pokemon Go mod menu by launching it on your device and selecting the features you want to activate. You can also adjust the settings and options according to your preferences. However, you need to be careful and smart about how you use it, as you could get banned or detected by the game developers. You also need to be responsible and respectful when using it, as you could affect your own or other players' gameplay experience.</p>
|
126 |
-
<li><strong>What are the risks and benefits of playing Pokemon Go with mod menu?</strong></li>
|
127 |
-
<p>Playing Pokemon Go with mod menu can have both positive and negative effects on your health, social life, and ethics. Some of the risks are getting banned or suspended from the game, losing your account or data, getting infected by viruses or malware, damaging your device or battery, harming your physical or mental health, losing interest or satisfaction in the game, ruining the gameplay experience for other players, breaking the law or ethics. Some of the benefits are catching more Pokemon, leveling up faster, winning more battles, completing more tasks, accessing more features and options, saving time and energy, improving your mood or relieving stress, discovering new places or experiences, making new friends or joining communities, expressing your creativity or personality.</p>
|
128 |
-
</ol></p> 401be4b1e0<br />
|
129 |
-
<br />
|
130 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1phancelerku/anime-remove-background/Enjoy Tsukis Odyssey MOD APK with No Ads and More Carrots.md
DELETED
@@ -1,117 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>Tsuki Odyssey Mod Apk: A Relaxing Adventure Game with a Cute Rabbit</h1>
|
3 |
-
<p>If you are looking for a game that can help you relax and unwind from the stress of everyday life, you might want to check out <strong>Tsuki Odyssey</strong>. This is a passive adventure game that immerses you into the world of Tsuki, a cute white rabbit who moves back to his hometown of Mushroom Village. In this game, you can decorate your home, make friends, catch all kinds of fish, and so much more. You can also explore different locations and discover new events and secrets. But what if you want to enjoy the game without any limitations or restrictions? Well, you can do that by downloading and installing <strong>Tsuki Odyssey mod apk</strong>. In this article, we will tell you everything you need to know about this game, its features, how to download and install the mod apk, how to play it on PC or Mac, and some tips and tricks for playing it.</p>
|
4 |
-
<h2>tsuki odyssey mod apk</h2><br /><p><b><b>DOWNLOAD</b> »»» <a href="https://jinyurl.com/2uNMs6">https://jinyurl.com/2uNMs6</a></b></p><br /><br />
|
5 |
-
<h2>What is Tsuki Odyssey?</h2>
|
6 |
-
<p>Tsuki Odyssey is a mobile game developed by RapBot Studios and released for iOS and Android by HyperBeard in 2021. It serves as a spiritual successor (and a soft reboot) to <strong>Tsuki Adventure</strong>, a game that was released in 2018. It shares a similar premise with its predecessor: a rabbit named Tsuki, having grown dissatisfied with his paper-pushing office job, abandons his life in the city and moves back to his quiet hometown of Mushroom Village, taking over his late grandfather's carrot farm. As in the first game, the player does not have direct control over what Tsuki does. Instead, the game revolves around checking in on him periodically and seeing what he gets up to on his own. The player can move Tsuki around with the world map, buy items and furniture, interact with the other residents of Mushroom Village, and enjoy hobbies like fishing.</p>
|
7 |
-
<p>However, Tsuki Odyssey is not just a copy of Tsuki Adventure. It offers a different gaming experience that is more immersive and interactive. For example, the game has more locations to explore, such as the bar, the workshop, the town hall, and the river. The game also has more events and secrets to discover, such as bounties, gachapon toys, hidden characters, and special quests. The game also has more customization options for your home, such as floorboards, wallpaper, décor, and furniture. The game also has more hobbies for Tsuki to enjoy, such as yoga, writing, and gardening. The game also has more collectibles to find, such as items, furniture, gachapon toys, and bounties. The game also has more characters to meet and befriend, such as Bobo the monkey, Chi the panda, Yori the fox, and Moca the cat. The game also has more dialogue and storylines to enjoy, such as Tsuki's memories, dreams, and adventures. In short, Tsuki Odyssey is a game that offers a lot of content and variety for the player to explore and experience.</p>
|
8 |
-
<h2>What are the features of Tsuki Odyssey?</h2>
|
9 |
-
<p>As we have mentioned, Tsuki Odyssey is a game that has a lot of features that make it fun and relaxing to play. Here are some of the main features of the game:</p>
|
10 |
-
<ul>
|
11 |
-
<li><strong>Decorate your home</strong>: You can customize your home by buying and placing different items and furniture. You can also change the floorboards, wallpaper, décor, and layout of your home. You can make your home cozy, stylish, or quirky according to your preference. You can also unlock new rooms and areas in your home as you progress in the game.</li>
|
12 |
-
<li><strong>Make friends</strong>: You can interact with the other residents of Mushroom Village and other locations. You can chat with them, give them gifts, help them with their problems, or join them in their activities. You can also unlock new characters and stories as you build your friendship with them. You can also visit their homes and see how they live.</li>
|
13 |
-
<li><strong>Catch all kinds of fish</strong>: You can go fishing in the river or the sea. You can catch different kinds of fish, from common ones like carp and trout to rare ones like shark and whale. You can also collect fishing rods, baits, and lures to improve your fishing skills. You can also sell your fish for carrots or display them in your home.</li>
|
14 |
-
<li><strong>Explore different locations</strong>: You can travel to different locations using the world map. You can visit places like the bar, the workshop, the town hall, the river, the forest, the beach, and more. You can also discover new locations as you progress in the game. You can also find new events and secrets in each location.</li>
|
15 |
-
<li><strong>Collect items, furniture, gachapon toys, and bounties</strong>: You can collect various things in the game. You can buy items and furniture from shops or find them in chests or crates. You can also use gacha tickets to get gachapon toys from vending machines. You can also complete bounties by finding specific items or characters in exchange for rewards.</li>
|
16 |
-
<li><strong>Enjoy hobbies</strong>: You can enjoy different hobbies in the game. You can do yoga with Chi at the town hall. You can write in your diary or read books at your home. You can garden with Bobo at his farm. You can also unlock new hobbies as you progress in the game.</li>
|
17 |
-
</ul>
|
18 |
-
<p>These are just some of the features of Tsuki Odyssey. There are many more things to do and see in this game that will keep you entertained and relaxed.</p>
|
19 |
-
<p>tsuki odyssey mod apk unlimited carrots<br />
|
20 |
-
tsuki odyssey mod apk latest version<br />
|
21 |
-
tsuki odyssey mod apk download for android<br />
|
22 |
-
tsuki odyssey mod apk free shopping<br />
|
23 |
-
tsuki odyssey mod apk 1.0.7<br />
|
24 |
-
tsuki odyssey mod apk an1<br />
|
25 |
-
tsuki odyssey mod apk happymod<br />
|
26 |
-
tsuki odyssey mod apk revdl<br />
|
27 |
-
tsuki odyssey mod apk rexdl<br />
|
28 |
-
tsuki odyssey mod apk android 1<br />
|
29 |
-
tsuki odyssey mod apk no ads<br />
|
30 |
-
tsuki odyssey mod apk offline<br />
|
31 |
-
tsuki odyssey mod apk unlimited money<br />
|
32 |
-
tsuki odyssey mod apk 2023<br />
|
33 |
-
tsuki odyssey mod apk obb<br />
|
34 |
-
tsuki odyssey mod apk pure<br />
|
35 |
-
tsuki odyssey mod apk platinmods<br />
|
36 |
-
tsuki odyssey mod apk vip<br />
|
37 |
-
tsuki odyssey mod apk pro<br />
|
38 |
-
tsuki odyssey mod apk premium<br />
|
39 |
-
tsuki odyssey mod apk full unlocked<br />
|
40 |
-
tsuki odyssey mod apk mega<br />
|
41 |
-
tsuki odyssey mod apk mediafıre<br />
|
42 |
-
tsuki odyssey mod apk apkpure<br />
|
43 |
-
tsuki odyssey mod apk apkmody<br />
|
44 |
-
tsuki odyssey mod apk apkmirror<br />
|
45 |
-
tsuki odyssey mod apk apknite<br />
|
46 |
-
tsuki odyssey mod apk apksolo<br />
|
47 |
-
tsuki odyssey mod apk apksmash<br />
|
48 |
-
tsuki odyssey mod apk apksweet<br />
|
49 |
-
tsuki odyssey mod apk apktada<br />
|
50 |
-
tsuki odyssey mod apk apktovi<br />
|
51 |
-
tsuki odyssey mod apk apktoko<br />
|
52 |
-
tsuki odyssey mod apk apktada.com<br />
|
53 |
-
tsuki odyssey mod apk apktwist.com<br />
|
54 |
-
tsuki odyssey mod apk apkturbo.com<br />
|
55 |
-
tsuki odyssey mod apk apktouch.com<br />
|
56 |
-
tsuki odyssey mod apk apktreat.com<br />
|
57 |
-
tsuki odyssey mod apk apktrend.com<br />
|
58 |
-
tsuki odyssey mod apk apktune.com<br />
|
59 |
-
tsuki odyssey mod apk apktown.com<br />
|
60 |
-
tsuki odyssey mod apk apktube.com<br />
|
61 |
-
tsuki odyssey mod apk aptoide.com<br />
|
62 |
-
tsuki odyssey hack cheat tool generator online 2023 working 100%</p>
|
63 |
-
<h2>How to download and install Tsuki Odyssey mod apk?</h2>
|
64 |
-
<p>Tsuki Odyssey is a free-to-play game that you can download from the App Store or Google Play Store. However, if you want to enjoy the game without any limitations or restrictions, you might want to use a mod apk for Tsuki Odyssey. A mod apk is a modified version of an app that gives you access to features that are not available in the original app. For example, a mod apk for Tsuki Odyssey might give you unlimited carrots (the currency of the game), free gacha tickets (to get gachapon toys), unlocked locations (to explore new places), unlocked characters (to meet new friends), or other benefits that will make your gaming experience more enjoyable.</p>
|
65 |
-
<p>If you want to download and install a mod apk for Tsuki Odyssey on your Android device, here are the steps you need to follow:</p>
|
66 |
-
<ol>
|
67 |
-
<li>Find a reliable source for downloading the mod apk file. There are many websites that offer mod apk files for various apps and games, but not all of them are safe or trustworthy. Some of them might contain malware or viruses that could harm your device or steal your personal information. Therefore, you should do some research before downloading any mod apk file from any website. You should check the reviews, ratings, comments, and feedback from other users who have downloaded the mod apk file from that website. You should also scan the mod apk file with an antivirus software before installing it on your device.</li>
|
68 |
-
<li>Enable unknown sources on your device. By default, Android devices do not allow installing apps from unknown sources, meaning sources other than the official app stores. However, since you are downloading a mod apk file from a third-party website, you need to enable unknown sources on your device to allow installing it. To do this, go to your device's settings, then security, then unknown sources, and toggle it on. You might see a warning message that installing apps from unknown sources could harm your device or data, but you can ignore it if you trust the source of the mod apk file.</li>
|
69 |
-
<li>Download the mod apk file from the website. Once you have found a reliable source for the mod apk file, you can download it from the website. You might need to click on a download button or link, or complete a captcha or survey to start the download. You might also see some pop-up ads or redirects that could be annoying or misleading, but you can close them or go back to the original website. The download might take some time depending on the size of the mod apk file and your internet speed.</li>
|
70 |
-
<li>Install the mod apk file on your device. After the download is complete, you can install the mod apk file on your device. You can find the mod apk file in your device's downloads folder or in the notification bar. You can tap on the mod apk file to start the installation process. You might see a prompt asking you to confirm the installation or grant some permissions to the app. You can follow the instructions on the screen to complete the installation.</li>
|
71 |
-
<li>Launch Tsuki Odyssey mod apk on your device. Once the installation is done, you can launch Tsuki Odyssey mod apk on your device. You can find the app icon on your device's home screen or app drawer. You can tap on the app icon to open it and start playing Tsuki Odyssey with all the benefits of the mod apk.</li>
|
72 |
-
</ol>
|
73 |
-
<p>These are the steps to download and install Tsuki Odyssey mod apk on your Android device. However, before you use a mod apk for Tsuki Odyssey, there are some precautions you need to take:</p>
|
74 |
-
<ul>
|
75 |
-
<li><strong>Backup your data</strong>: Using a mod apk for Tsuki Odyssey might overwrite or delete your original game data, such as your progress, achievements, items, and carrots. Therefore, you should backup your data before using a mod apk for Tsuki Odyssey. You can do this by using a cloud service like Google Drive or Dropbox, or by using an app like Helium or Titanium Backup.</li>
|
76 |
-
<li><strong>Disable automatic updates</strong>: Using a mod apk for Tsuki Odyssey might prevent you from getting updates from the official app store. Therefore, you should disable automatic updates for Tsuki Odyssey before using a mod apk for Tsuki Odyssey. You can do this by going to your device's settings, then apps, then Tsuki Odyssey, then disable auto-update.</li>
|
77 |
-
<li><strong>Use a VPN</strong>: Using a mod apk for Tsuki Odyssey might expose you to security risks or legal issues. Therefore, you should use a VPN (virtual private network) before using a mod apk for Tsuki Odyssey. A VPN will encrypt your internet traffic and hide your IP address, making it harder for anyone to track or monitor your online activity. You can use a free or paid VPN service like ExpressVPN, NordVPN, or TunnelBear.</li>
|
78 |
-
</ul>
|
79 |
-
<p>These are some of the precautions you need to take before using a mod apk for Tsuki Odyssey.</p>
|
80 |
-
<h2>How to play Tsuki Odyssey on PC or Mac?</h2>
|
81 |
-
<p>Tsuki Odyssey is a mobile game that is designed for iOS and Android devices. However, if you want to play Tsuki Odyssey on a bigger screen with better graphics and performance, you might want to play it on PC or Mac. To do this, you need to use an emulator. An emulator is a software that allows you to run mobile apps and games on your PC or Mac as if they were native apps and games. There are many emulators available for PC and Mac, such as BlueStacks, NoxPlayer, MEmu, LDPlayer, and more.</p>
|
82 |
-
<p>If you want to play Tsuki Odyssey on PC or Mac using an emulator, here are the steps you need to follow:</p>
|
83 |
-
<ol>
|
84 |
-
<li>Download and install an emulator on your PC or Mac. You can choose any emulator that suits your preference and system requirements. You can find and download emulators from their official websites or from other sources online. The download and installation process might vary depending on the emulator and your operating system, but generally it involves clicking on an installer file and following the instructions on the screen.</li>
|
85 |
-
<li>Launch the emulator on your PC or Mac. After installing the emulator, you can launch it on your PC or Mac by clicking on its icon or shortcut. You might see a welcome screen or a tutorial that will guide you through setting up the emulator and its features.</li>
|
86 |
-
<li <li>Download and install Tsuki Odyssey on your emulator. You can download Tsuki Odyssey from the app store of your emulator, such as Google Play Store or Apple App Store. You can also download Tsuki Odyssey mod apk from a third-party website and install it on your emulator using the same steps as mentioned above. The download and installation process might vary depending on the emulator and the app source, but generally it involves searching for the app, clicking on the install button, and waiting for the app to be installed.</li>
|
87 |
-
<li>Launch Tsuki Odyssey on your emulator. After installing Tsuki Odyssey, you can launch it on your emulator by clicking on its icon or shortcut. You might see a loading screen or a splash screen that will take you to the main menu of the game. You can then start playing Tsuki Odyssey on your PC or Mac as if you were playing it on your mobile device.</li>
|
88 |
-
</ol>
|
89 |
-
<p>These are the steps to play Tsuki Odyssey on PC or Mac using an emulator.</p>
|
90 |
-
<h2>Tips and tricks for playing Tsuki Odyssey</h2>
|
91 |
-
<p>Tsuki Odyssey is a game that does not require your constant input, but rewards you for checking in often and seeing what happens in the town. However, if you want to progress faster in the game and get more out of it, you might want to use some tips and tricks for playing Tsuki Odyssey. Here are some of them:</p>
|
92 |
-
<ul>
|
93 |
-
<li><strong>How to progress faster in Tsuki Odyssey</strong>: To progress faster in Tsuki Odyssey, you need to increase your level and unlock new locations and characters. To do this, you need to collect experience points (XP) by doing various things in the game, such as interacting with characters, buying items, fishing, completing bounties, and finding secrets. You can also get XP by watching ads or using gacha tickets. You can see your XP bar at the top of the screen, and when it fills up, you will level up and unlock new things.</li>
|
94 |
-
<li><strong>How to get free carrots in Tsuki Odyssey</strong>: Carrots are the currency of the game that you can use to buy items, furniture, gachapon toys, and travel tickets. You can get carrots by doing various things in the game, such as selling fish, completing bounties, finding chests or crates, watching ads, or using gacha tickets. You can also get carrots by tapping on the carrot farm at your home or by tapping on the carrot icon at the bottom right of the screen. You can also get carrots by using a mod apk for Tsuki Odyssey that gives you unlimited carrots.</li>
|
95 |
-
<li><strong>How to use gacha tickets in Tsuki Odyssey</strong>: Gacha tickets are special items that you can use to get gachapon toys from vending machines. Gachapon toys are cute figurines that you can collect and display in your home. There are different types of gachapon toys, such as animals, food, vehicles, and more. You can use gacha tickets by tapping on the gacha icon at the bottom left of the screen. You can then choose which vending machine you want to use and how many tickets you want to spend. You can then see what gachapon toys you get and add them to your collection.</li>
|
96 |
-
<li><strong>How to unlock new locations and characters in Tsuki Odyssey</strong>: To unlock new locations and characters in Tsuki Odyssey, you need to level up and travel to different places using travel tickets. Travel tickets are special items that you can use to visit places like the forest, the beach, the city, and more. You can get travel tickets by buying them from shops or finding them in chests or crates. You can also get travel tickets by using a mod apk for Tsuki Odyssey that gives you unlimited travel tickets. You can use travel tickets by tapping on the world map icon at the bottom right of the screen. You can then choose which location you want to visit and how many tickets you want to spend. You can then see what happens in that location and meet new characters.</li>
|
97 |
-
</ul>
|
98 |
-
<p>These are some of the tips and tricks for playing Tsuki Odyssey.</p>
|
99 |
-
<h2>Conclusion</h2>
|
100 |
-
<p>Tsuki Odyssey is a relaxing adventure game with a cute rabbit that will make you feel calm and happy. It is a game that does not require your constant input, but rewards you for checking in often and seeing what happens in the town. It is a game that has a lot of features that make it fun and immersive to play. It is a game that you can download from the app store or use a mod apk for more benefits. It is a game that you can play on your mobile device or on your PC or Mac using an emulator. It is a game that you can enjoy with some tips and tricks.</p>
|
101 |
-
<p>If you are looking for a game that can help you relax and unwind from the stress of everyday life, you might want to give Tsuki Odyssey a try. It is a game that will make you smile and relax with its cute graphics, soothing music, and charming characters. It is a game that will let you escape from reality and immerse yourself into a world of peace and tranquility. It is a game that will make you feel like you are living a simple and happy life with a cute rabbit.</p>
|
102 |
-
<h2>FAQs</h2>
|
103 |
-
<p>Here are some of the frequently asked questions about Tsuki Odyssey:</p>
|
104 |
-
<ol>
|
105 |
-
<li><strong>Is Tsuki Odyssey online or offline?</strong></li>
|
106 |
-
<p>Tsuki Odyssey is an offline game that does not require an internet connection to play. However, you might need an internet connection to download the game, update the game, watch ads, or use some features of the game.</p>
|
107 |
-
<li><strong>Is Tsuki Odyssey free or paid?</strong></li>
|
108 |
-
<p>Tsuki Odyssey is a free-to-play game that does not require any payment to download or play. However, the game has some optional in-app purchases that can enhance your gaming experience, such as buying carrots, gacha tickets, or travel tickets. You can also use a mod apk for Tsuki Odyssey that gives you these benefits for free.</p>
|
109 |
-
<li><strong>Is Tsuki Odyssey safe or harmful?</strong></li>
|
110 |
-
<p>Tsuki Odyssey is a safe game that does not contain any harmful content or malware. However, you should be careful when downloading and installing a mod apk for Tsuki Odyssey from a third-party website, as it might contain malware or viruses that could harm your device or data. You should also backup your data, disable automatic updates, and use a VPN before using a mod apk for Tsuki Odyssey.</p>
|
111 |
-
<li><strong>Is Tsuki Odyssey easy or hard?</strong></li>
|
112 |
-
<p>Tsuki Odyssey is an easy game that does not require any skill or strategy to play. It is a game that does not have any goals or challenges to complete. It is a game that does not have any timers or deadlines to meet. It is a game that does not have any enemies or dangers to avoid. It is a game that does not have any failure or game over scenarios. It is a game that lets you play at your own pace and enjoy the game as you wish.</p>
|
113 |
-
<li><strong>Is Tsuki Odyssey fun or boring?</strong></li>
|
114 |
-
<p>Tsuki Odyssey is a fun game that has a lot of content and variety to offer. It is a game that has many features that make it fun and immersive to play. It is a game that has many locations and characters to explore and interact with. It is a game that has many events and secrets to discover and experience. It is a game that has many items and collectibles to find and display. It is a game that has many hobbies and activities to enjoy and relax with. It is a game that will keep you entertained and relaxed for hours.</p>
|
115 |
-
</ol></p> 197e85843d<br />
|
116 |
-
<br />
|
117 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/1toTree/lora_test/ppdiffusers/pipelines/paint_by_example/__init__.py
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
# Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved.
|
2 |
-
#
|
3 |
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4 |
-
# you may not use this file except in compliance with the License.
|
5 |
-
# You may obtain a copy of the License at
|
6 |
-
#
|
7 |
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8 |
-
#
|
9 |
-
# Unless required by applicable law or agreed to in writing, software
|
10 |
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11 |
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12 |
-
# See the License for the specific language governing permissions and
|
13 |
-
# limitations under the License.
|
14 |
-
|
15 |
-
from dataclasses import dataclass
|
16 |
-
from typing import List, Optional, Union
|
17 |
-
|
18 |
-
import numpy as np
|
19 |
-
import PIL
|
20 |
-
from PIL import Image
|
21 |
-
|
22 |
-
from ...utils import is_paddle_available, is_paddlenlp_available
|
23 |
-
|
24 |
-
if is_paddlenlp_available() and is_paddle_available():
|
25 |
-
from .image_encoder import PaintByExampleImageEncoder
|
26 |
-
from .pipeline_paint_by_example import PaintByExamplePipeline
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/2023Liu2023/bingo/src/app/layout.tsx
DELETED
@@ -1,47 +0,0 @@
|
|
1 |
-
import { Metadata } from 'next'
|
2 |
-
import { Toaster } from 'react-hot-toast'
|
3 |
-
import { TailwindIndicator } from '@/components/tailwind-indicator'
|
4 |
-
import { Providers } from '@/components/providers'
|
5 |
-
import { Header } from '@/components/header'
|
6 |
-
|
7 |
-
import '@/app/globals.scss'
|
8 |
-
|
9 |
-
|
10 |
-
export const metadata: Metadata = {
|
11 |
-
title: {
|
12 |
-
default: 'Bing AI Chatbot',
|
13 |
-
template: `%s - Bing AI Chatbot`
|
14 |
-
},
|
15 |
-
description: 'Bing AI Chatbot Web App.',
|
16 |
-
themeColor: [
|
17 |
-
{ media: '(prefers-color-scheme: light)', color: 'white' },
|
18 |
-
{ media: '(prefers-color-scheme: dark)', color: 'dark' }
|
19 |
-
],
|
20 |
-
icons: {
|
21 |
-
icon: '/favicon.ico',
|
22 |
-
shortcut: '../assets/images/logo.svg',
|
23 |
-
apple: '../assets/images/logo.svg'
|
24 |
-
}
|
25 |
-
}
|
26 |
-
|
27 |
-
interface RootLayoutProps {
|
28 |
-
children: React.ReactNode
|
29 |
-
}
|
30 |
-
|
31 |
-
export default function RootLayout({ children }: RootLayoutProps) {
|
32 |
-
return (
|
33 |
-
<html lang="zh-CN" suppressHydrationWarning>
|
34 |
-
<body>
|
35 |
-
<Toaster />
|
36 |
-
<Providers attribute="class" defaultTheme="system" enableSystem>
|
37 |
-
<div className="flex flex-col min-h-screen">
|
38 |
-
{/* @ts-ignore */}
|
39 |
-
<Header />
|
40 |
-
<main className="flex flex-col flex-1">{children}</main>
|
41 |
-
</div>
|
42 |
-
<TailwindIndicator />
|
43 |
-
</Providers>
|
44 |
-
</body>
|
45 |
-
</html>
|
46 |
-
)
|
47 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/801artistry/RVC801/infer/modules/train/extract/extract_f0_print.py
DELETED
@@ -1,298 +0,0 @@
|
|
1 |
-
import os
|
2 |
-
import sys
|
3 |
-
import traceback
|
4 |
-
|
5 |
-
import parselmouth
|
6 |
-
|
7 |
-
now_dir = os.getcwd()
|
8 |
-
sys.path.append(now_dir)
|
9 |
-
import logging
|
10 |
-
from LazyImport import lazyload
|
11 |
-
|
12 |
-
import numpy as np
|
13 |
-
import pyworld
|
14 |
-
torchcrepe = lazyload("torchcrepe") # Fork Feature. Crepe algo for training and preprocess
|
15 |
-
torch = lazyload("torch")
|
16 |
-
#from torch import Tensor # Fork Feature. Used for pitch prediction for torch crepe.
|
17 |
-
tqdm = lazyload("tqdm")
|
18 |
-
from infer.lib.audio import load_audio
|
19 |
-
|
20 |
-
logging.getLogger("numba").setLevel(logging.WARNING)
|
21 |
-
from multiprocessing import Process
|
22 |
-
|
23 |
-
exp_dir = sys.argv[1]
|
24 |
-
f = open("%s/extract_f0_feature.log" % exp_dir, "a+")
|
25 |
-
|
26 |
-
DoFormant = False
|
27 |
-
Quefrency = 1.0
|
28 |
-
Timbre = 1.0
|
29 |
-
|
30 |
-
def printt(strr):
|
31 |
-
print(strr)
|
32 |
-
f.write(f"{strr}\n")
|
33 |
-
f.flush()
|
34 |
-
|
35 |
-
|
36 |
-
n_p = int(sys.argv[2])
|
37 |
-
f0method = sys.argv[3]
|
38 |
-
extraction_crepe_hop_length = 0
|
39 |
-
try:
|
40 |
-
extraction_crepe_hop_length = int(sys.argv[4])
|
41 |
-
except:
|
42 |
-
print("Temp Issue. echl is not being passed with argument!")
|
43 |
-
extraction_crepe_hop_length = 128
|
44 |
-
|
45 |
-
class FeatureInput(object):
|
46 |
-
def __init__(self, samplerate=16000, hop_size=160):
|
47 |
-
self.fs = samplerate
|
48 |
-
self.hop = hop_size
|
49 |
-
|
50 |
-
self.f0_bin = 256
|
51 |
-
self.f0_max = 1100.0
|
52 |
-
self.f0_min = 50.0
|
53 |
-
self.f0_mel_min = 1127 * np.log(1 + self.f0_min / 700)
|
54 |
-
self.f0_mel_max = 1127 * np.log(1 + self.f0_max / 700)
|
55 |
-
|
56 |
-
def mncrepe(self, method, x, p_len, crepe_hop_length):
|
57 |
-
f0 = None
|
58 |
-
torch_device_index = 0
|
59 |
-
torch_device = torch.device(
|
60 |
-
f"cuda:{torch_device_index % torch.cuda.device_count()}"
|
61 |
-
) if torch.cuda.is_available() \
|
62 |
-
else torch.device("mps") if torch.backends.mps.is_available() \
|
63 |
-
else torch.device("cpu")
|
64 |
-
|
65 |
-
audio = torch.from_numpy(x.astype(np.float32)).to(torch_device, copy=True)
|
66 |
-
audio /= torch.quantile(torch.abs(audio), 0.999)
|
67 |
-
audio = torch.unsqueeze(audio, dim=0)
|
68 |
-
if audio.ndim == 2 and audio.shape[0] > 1:
|
69 |
-
audio = torch.mean(audio, dim=0, keepdim=True).detach()
|
70 |
-
audio = audio.detach()
|
71 |
-
|
72 |
-
if method == 'mangio-crepe':
|
73 |
-
pitch: torch.Tensor = torchcrepe.predict(
|
74 |
-
audio,
|
75 |
-
self.fs,
|
76 |
-
crepe_hop_length,
|
77 |
-
self.f0_min,
|
78 |
-
self.f0_max,
|
79 |
-
"full",
|
80 |
-
batch_size=crepe_hop_length * 2,
|
81 |
-
device=torch_device,
|
82 |
-
pad=True,
|
83 |
-
)
|
84 |
-
p_len = p_len or x.shape[0] // crepe_hop_length
|
85 |
-
# Resize the pitch
|
86 |
-
source = np.array(pitch.squeeze(0).cpu().float().numpy())
|
87 |
-
source[source < 0.001] = np.nan
|
88 |
-
target = np.interp(
|
89 |
-
np.arange(0, len(source) * p_len, len(source)) / p_len,
|
90 |
-
np.arange(0, len(source)),
|
91 |
-
source,
|
92 |
-
)
|
93 |
-
f0 = np.nan_to_num(target)
|
94 |
-
|
95 |
-
elif method == 'crepe':
|
96 |
-
batch_size = 512
|
97 |
-
audio = torch.tensor(np.copy(x))[None].float()
|
98 |
-
f0, pd = torchcrepe.predict(
|
99 |
-
audio,
|
100 |
-
self.fs,
|
101 |
-
160,
|
102 |
-
self.f0_min,
|
103 |
-
self.f0_max,
|
104 |
-
"full",
|
105 |
-
batch_size=batch_size,
|
106 |
-
device=torch_device,
|
107 |
-
return_periodicity=True,
|
108 |
-
)
|
109 |
-
pd = torchcrepe.filter.median(pd, 3)
|
110 |
-
f0 = torchcrepe.filter.mean(f0, 3)
|
111 |
-
f0[pd < 0.1] = 0
|
112 |
-
f0 = f0[0].cpu().numpy()
|
113 |
-
f0 = f0[1:] # Get rid of extra first frame
|
114 |
-
|
115 |
-
return f0
|
116 |
-
|
117 |
-
def get_pm(self, x, p_len):
|
118 |
-
f0 = parselmouth.Sound(x, self.fs).to_pitch_ac(
|
119 |
-
time_step=160 / 16000,
|
120 |
-
voicing_threshold=0.6,
|
121 |
-
pitch_floor=self.f0_min,
|
122 |
-
pitch_ceiling=self.f0_max,
|
123 |
-
).selected_array["frequency"]
|
124 |
-
|
125 |
-
return np.pad(
|
126 |
-
f0,
|
127 |
-
[[max(0, (p_len - len(f0) + 1) // 2), max(0, p_len - len(f0) - (p_len - len(f0) + 1) // 2)]],
|
128 |
-
mode="constant"
|
129 |
-
)
|
130 |
-
|
131 |
-
def get_harvest(self, x):
|
132 |
-
f0_spectral = pyworld.harvest(
|
133 |
-
x.astype(np.double),
|
134 |
-
fs=self.fs,
|
135 |
-
f0_ceil=self.f0_max,
|
136 |
-
f0_floor=self.f0_min,
|
137 |
-
frame_period=1000 * self.hop / self.fs,
|
138 |
-
)
|
139 |
-
return pyworld.stonemask(x.astype(np.double), *f0_spectral, self.fs)
|
140 |
-
|
141 |
-
def get_dio(self, x):
|
142 |
-
f0_spectral = pyworld.dio(
|
143 |
-
x.astype(np.double),
|
144 |
-
fs=self.fs,
|
145 |
-
f0_ceil=self.f0_max,
|
146 |
-
f0_floor=self.f0_min,
|
147 |
-
frame_period=1000 * self.hop / self.fs,
|
148 |
-
)
|
149 |
-
return pyworld.stonemask(x.astype(np.double), *f0_spectral, self.fs)
|
150 |
-
|
151 |
-
def get_rmvpe(self, x):
|
152 |
-
if hasattr(self, "model_rmvpe") == False:
|
153 |
-
from infer.lib.rmvpe import RMVPE
|
154 |
-
|
155 |
-
print("Loading rmvpe model")
|
156 |
-
self.model_rmvpe = RMVPE(
|
157 |
-
"assets/rmvpe/rmvpe.pt", is_half=False, device="cpu"
|
158 |
-
)
|
159 |
-
return self.model_rmvpe.infer_from_audio(x, thred=0.03)
|
160 |
-
|
161 |
-
def get_rmvpe_dml(self, x):
|
162 |
-
...
|
163 |
-
|
164 |
-
def get_f0_method_dict(self):
|
165 |
-
return {
|
166 |
-
"pm": self.get_pm,
|
167 |
-
"harvest": self.get_harvest,
|
168 |
-
"dio": self.get_dio,
|
169 |
-
"rmvpe": self.get_rmvpe
|
170 |
-
}
|
171 |
-
|
172 |
-
def get_f0_hybrid_computation(
|
173 |
-
self,
|
174 |
-
methods_str,
|
175 |
-
x,
|
176 |
-
p_len,
|
177 |
-
crepe_hop_length,
|
178 |
-
):
|
179 |
-
# Get various f0 methods from input to use in the computation stack
|
180 |
-
s = methods_str
|
181 |
-
s = s.split("hybrid")[1]
|
182 |
-
s = s.replace("[", "").replace("]", "")
|
183 |
-
methods = s.split("+")
|
184 |
-
f0_computation_stack = []
|
185 |
-
|
186 |
-
for method in methods:
|
187 |
-
if method in self.f0_method_dict:
|
188 |
-
f0 = self.f0_method_dict[method](x, p_len) if method == 'pm' else self.f0_method_dict[method](x)
|
189 |
-
f0_computation_stack.append(f0)
|
190 |
-
elif method == 'crepe' or method == 'mangio-crepe':
|
191 |
-
self.the_other_complex_function(x, method, crepe_hop_length)
|
192 |
-
|
193 |
-
if len(f0_computation_stack) != 0:
|
194 |
-
f0_median_hybrid = np.nanmedian(f0_computation_stack, axis=0) if len(f0_computation_stack)>1 else f0_computation_stack[0]
|
195 |
-
return f0_median_hybrid
|
196 |
-
else:
|
197 |
-
raise ValueError("No valid methods were provided")
|
198 |
-
|
199 |
-
def compute_f0(self, path, f0_method, crepe_hop_length):
|
200 |
-
x = load_audio(path, self.fs, DoFormant, Quefrency, Timbre)
|
201 |
-
p_len = x.shape[0] // self.hop
|
202 |
-
|
203 |
-
if f0_method in self.f0_method_dict:
|
204 |
-
f0 = self.f0_method_dict[f0_method](x, p_len) if f0_method == 'pm' else self.f0_method_dict[f0_method](x)
|
205 |
-
elif f0_method in ['crepe', 'mangio-crepe']:
|
206 |
-
f0 = self.mncrepe(f0_method, x, p_len, crepe_hop_length)
|
207 |
-
elif "hybrid" in f0_method: # EXPERIMENTAL
|
208 |
-
# Perform hybrid median pitch estimation
|
209 |
-
f0 = self.get_f0_hybrid_computation(
|
210 |
-
f0_method,
|
211 |
-
x,
|
212 |
-
p_len,
|
213 |
-
crepe_hop_length,
|
214 |
-
)
|
215 |
-
return f0
|
216 |
-
|
217 |
-
def coarse_f0(self, f0):
|
218 |
-
f0_mel = 1127 * np.log(1 + f0 / 700)
|
219 |
-
f0_mel[f0_mel > 0] = (f0_mel[f0_mel > 0] - self.f0_mel_min) * (
|
220 |
-
self.f0_bin - 2
|
221 |
-
) / (self.f0_mel_max - self.f0_mel_min) + 1
|
222 |
-
|
223 |
-
# use 0 or 1
|
224 |
-
f0_mel[f0_mel <= 1] = 1
|
225 |
-
f0_mel[f0_mel > self.f0_bin - 1] = self.f0_bin - 1
|
226 |
-
f0_coarse = np.rint(f0_mel).astype(int)
|
227 |
-
assert f0_coarse.max() <= 255 and f0_coarse.min() >= 1, (
|
228 |
-
f0_coarse.max(),
|
229 |
-
f0_coarse.min(),
|
230 |
-
)
|
231 |
-
return f0_coarse
|
232 |
-
|
233 |
-
def go(self, paths, f0_method, crepe_hop_length, thread_n):
|
234 |
-
if len(paths) == 0:
|
235 |
-
printt("no-f0-todo")
|
236 |
-
return
|
237 |
-
with tqdm.tqdm(total=len(paths), leave=True, position=thread_n) as pbar:
|
238 |
-
description = f"thread:{thread_n}, f0ing, Hop-Length:{crepe_hop_length}"
|
239 |
-
pbar.set_description(description)
|
240 |
-
|
241 |
-
for idx, (inp_path, opt_path1, opt_path2) in enumerate(paths):
|
242 |
-
try:
|
243 |
-
if (
|
244 |
-
os.path.exists(opt_path1 + ".npy")
|
245 |
-
and os.path.exists(opt_path2 + ".npy")
|
246 |
-
):
|
247 |
-
pbar.update(1)
|
248 |
-
continue
|
249 |
-
|
250 |
-
featur_pit = self.compute_f0(inp_path, f0_method, crepe_hop_length)
|
251 |
-
np.save(
|
252 |
-
opt_path2,
|
253 |
-
featur_pit,
|
254 |
-
allow_pickle=False,
|
255 |
-
) # nsf
|
256 |
-
coarse_pit = self.coarse_f0(featur_pit)
|
257 |
-
np.save(
|
258 |
-
opt_path1,
|
259 |
-
coarse_pit,
|
260 |
-
allow_pickle=False,
|
261 |
-
) # ori
|
262 |
-
pbar.update(1)
|
263 |
-
except Exception as e:
|
264 |
-
printt(f"f0fail-{idx}-{inp_path}-{traceback.format_exc()}")
|
265 |
-
|
266 |
-
|
267 |
-
if __name__ == "__main__":
|
268 |
-
# exp_dir=r"E:\codes\py39\dataset\mi-test"
|
269 |
-
# n_p=16
|
270 |
-
# f = open("%s/log_extract_f0.log"%exp_dir, "w")
|
271 |
-
printt(sys.argv)
|
272 |
-
featureInput = FeatureInput()
|
273 |
-
paths = []
|
274 |
-
inp_root = "%s/1_16k_wavs" % (exp_dir)
|
275 |
-
opt_root1 = "%s/2a_f0" % (exp_dir)
|
276 |
-
opt_root2 = "%s/2b-f0nsf" % (exp_dir)
|
277 |
-
|
278 |
-
os.makedirs(opt_root1, exist_ok=True)
|
279 |
-
os.makedirs(opt_root2, exist_ok=True)
|
280 |
-
for name in sorted(list(os.listdir(inp_root))):
|
281 |
-
inp_path = "%s/%s" % (inp_root, name)
|
282 |
-
if "spec" in inp_path:
|
283 |
-
continue
|
284 |
-
opt_path1 = "%s/%s" % (opt_root1, name)
|
285 |
-
opt_path2 = "%s/%s" % (opt_root2, name)
|
286 |
-
paths.append([inp_path, opt_path1, opt_path2])
|
287 |
-
|
288 |
-
ps = []
|
289 |
-
print("Using f0 method: " + f0method)
|
290 |
-
for i in range(n_p):
|
291 |
-
p = Process(
|
292 |
-
target=featureInput.go,
|
293 |
-
args=(paths[i::n_p], f0method, extraction_crepe_hop_length, i),
|
294 |
-
)
|
295 |
-
ps.append(p)
|
296 |
-
p.start()
|
297 |
-
for i in range(n_p):
|
298 |
-
ps[i].join()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AI-Hobbyist/Hoyo-RVC/infer_pack/onnx_inference.py
DELETED
@@ -1,143 +0,0 @@
|
|
1 |
-
import onnxruntime
|
2 |
-
import librosa
|
3 |
-
import numpy as np
|
4 |
-
import soundfile
|
5 |
-
|
6 |
-
|
7 |
-
class ContentVec:
|
8 |
-
def __init__(self, vec_path="pretrained/vec-768-layer-12.onnx", device=None):
|
9 |
-
print("load model(s) from {}".format(vec_path))
|
10 |
-
if device == "cpu" or device is None:
|
11 |
-
providers = ["CPUExecutionProvider"]
|
12 |
-
elif device == "cuda":
|
13 |
-
providers = ["CUDAExecutionProvider", "CPUExecutionProvider"]
|
14 |
-
elif device == "dml":
|
15 |
-
providers = ["DmlExecutionProvider"]
|
16 |
-
else:
|
17 |
-
raise RuntimeError("Unsportted Device")
|
18 |
-
self.model = onnxruntime.InferenceSession(vec_path, providers=providers)
|
19 |
-
|
20 |
-
def __call__(self, wav):
|
21 |
-
return self.forward(wav)
|
22 |
-
|
23 |
-
def forward(self, wav):
|
24 |
-
feats = wav
|
25 |
-
if feats.ndim == 2: # double channels
|
26 |
-
feats = feats.mean(-1)
|
27 |
-
assert feats.ndim == 1, feats.ndim
|
28 |
-
feats = np.expand_dims(np.expand_dims(feats, 0), 0)
|
29 |
-
onnx_input = {self.model.get_inputs()[0].name: feats}
|
30 |
-
logits = self.model.run(None, onnx_input)[0]
|
31 |
-
return logits.transpose(0, 2, 1)
|
32 |
-
|
33 |
-
|
34 |
-
def get_f0_predictor(f0_predictor, hop_length, sampling_rate, **kargs):
|
35 |
-
if f0_predictor == "pm":
|
36 |
-
from infer_pack.modules.F0Predictor.PMF0Predictor import PMF0Predictor
|
37 |
-
|
38 |
-
f0_predictor_object = PMF0Predictor(
|
39 |
-
hop_length=hop_length, sampling_rate=sampling_rate
|
40 |
-
)
|
41 |
-
elif f0_predictor == "harvest":
|
42 |
-
from infer_pack.modules.F0Predictor.HarvestF0Predictor import HarvestF0Predictor
|
43 |
-
|
44 |
-
f0_predictor_object = HarvestF0Predictor(
|
45 |
-
hop_length=hop_length, sampling_rate=sampling_rate
|
46 |
-
)
|
47 |
-
elif f0_predictor == "dio":
|
48 |
-
from infer_pack.modules.F0Predictor.DioF0Predictor import DioF0Predictor
|
49 |
-
|
50 |
-
f0_predictor_object = DioF0Predictor(
|
51 |
-
hop_length=hop_length, sampling_rate=sampling_rate
|
52 |
-
)
|
53 |
-
else:
|
54 |
-
raise Exception("Unknown f0 predictor")
|
55 |
-
return f0_predictor_object
|
56 |
-
|
57 |
-
|
58 |
-
class OnnxRVC:
|
59 |
-
def __init__(
|
60 |
-
self,
|
61 |
-
model_path,
|
62 |
-
sr=40000,
|
63 |
-
hop_size=512,
|
64 |
-
vec_path="vec-768-layer-12",
|
65 |
-
device="cpu",
|
66 |
-
):
|
67 |
-
vec_path = f"pretrained/{vec_path}.onnx"
|
68 |
-
self.vec_model = ContentVec(vec_path, device)
|
69 |
-
if device == "cpu" or device is None:
|
70 |
-
providers = ["CPUExecutionProvider"]
|
71 |
-
elif device == "cuda":
|
72 |
-
providers = ["CUDAExecutionProvider", "CPUExecutionProvider"]
|
73 |
-
elif device == "dml":
|
74 |
-
providers = ["DmlExecutionProvider"]
|
75 |
-
else:
|
76 |
-
raise RuntimeError("Unsportted Device")
|
77 |
-
self.model = onnxruntime.InferenceSession(model_path, providers=providers)
|
78 |
-
self.sampling_rate = sr
|
79 |
-
self.hop_size = hop_size
|
80 |
-
|
81 |
-
def forward(self, hubert, hubert_length, pitch, pitchf, ds, rnd):
|
82 |
-
onnx_input = {
|
83 |
-
self.model.get_inputs()[0].name: hubert,
|
84 |
-
self.model.get_inputs()[1].name: hubert_length,
|
85 |
-
self.model.get_inputs()[2].name: pitch,
|
86 |
-
self.model.get_inputs()[3].name: pitchf,
|
87 |
-
self.model.get_inputs()[4].name: ds,
|
88 |
-
self.model.get_inputs()[5].name: rnd,
|
89 |
-
}
|
90 |
-
return (self.model.run(None, onnx_input)[0] * 32767).astype(np.int16)
|
91 |
-
|
92 |
-
def inference(
|
93 |
-
self,
|
94 |
-
raw_path,
|
95 |
-
sid,
|
96 |
-
f0_method="dio",
|
97 |
-
f0_up_key=0,
|
98 |
-
pad_time=0.5,
|
99 |
-
cr_threshold=0.02,
|
100 |
-
):
|
101 |
-
f0_min = 50
|
102 |
-
f0_max = 1100
|
103 |
-
f0_mel_min = 1127 * np.log(1 + f0_min / 700)
|
104 |
-
f0_mel_max = 1127 * np.log(1 + f0_max / 700)
|
105 |
-
f0_predictor = get_f0_predictor(
|
106 |
-
f0_method,
|
107 |
-
hop_length=self.hop_size,
|
108 |
-
sampling_rate=self.sampling_rate,
|
109 |
-
threshold=cr_threshold,
|
110 |
-
)
|
111 |
-
wav, sr = librosa.load(raw_path, sr=self.sampling_rate)
|
112 |
-
org_length = len(wav)
|
113 |
-
if org_length / sr > 50.0:
|
114 |
-
raise RuntimeError("Reached Max Length")
|
115 |
-
|
116 |
-
wav16k = librosa.resample(wav, orig_sr=self.sampling_rate, target_sr=16000)
|
117 |
-
wav16k = wav16k
|
118 |
-
|
119 |
-
hubert = self.vec_model(wav16k)
|
120 |
-
hubert = np.repeat(hubert, 2, axis=2).transpose(0, 2, 1).astype(np.float32)
|
121 |
-
hubert_length = hubert.shape[1]
|
122 |
-
|
123 |
-
pitchf = f0_predictor.compute_f0(wav, hubert_length)
|
124 |
-
pitchf = pitchf * 2 ** (f0_up_key / 12)
|
125 |
-
pitch = pitchf.copy()
|
126 |
-
f0_mel = 1127 * np.log(1 + pitch / 700)
|
127 |
-
f0_mel[f0_mel > 0] = (f0_mel[f0_mel > 0] - f0_mel_min) * 254 / (
|
128 |
-
f0_mel_max - f0_mel_min
|
129 |
-
) + 1
|
130 |
-
f0_mel[f0_mel <= 1] = 1
|
131 |
-
f0_mel[f0_mel > 255] = 255
|
132 |
-
pitch = np.rint(f0_mel).astype(np.int64)
|
133 |
-
|
134 |
-
pitchf = pitchf.reshape(1, len(pitchf)).astype(np.float32)
|
135 |
-
pitch = pitch.reshape(1, len(pitch))
|
136 |
-
ds = np.array([sid]).astype(np.int64)
|
137 |
-
|
138 |
-
rnd = np.random.randn(1, 192, hubert_length).astype(np.float32)
|
139 |
-
hubert_length = np.array([hubert_length]).astype(np.int64)
|
140 |
-
|
141 |
-
out_wav = self.forward(hubert, hubert_length, pitch, pitchf, ds, rnd).squeeze()
|
142 |
-
out_wav = np.pad(out_wav, (0, 2 * self.hop_size), "constant")
|
143 |
-
return out_wav[0:org_length]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AIFILMS/generate_human_motion/pyrender/pyrender/shader_program.py
DELETED
@@ -1,283 +0,0 @@
|
|
1 |
-
"""OpenGL shader program wrapper.
|
2 |
-
"""
|
3 |
-
import numpy as np
|
4 |
-
import os
|
5 |
-
import re
|
6 |
-
|
7 |
-
import OpenGL
|
8 |
-
from OpenGL.GL import *
|
9 |
-
from OpenGL.GL import shaders as gl_shader_utils
|
10 |
-
|
11 |
-
|
12 |
-
class ShaderProgramCache(object):
|
13 |
-
"""A cache for shader programs.
|
14 |
-
"""
|
15 |
-
|
16 |
-
def __init__(self, shader_dir=None):
|
17 |
-
self._program_cache = {}
|
18 |
-
self.shader_dir = shader_dir
|
19 |
-
if self.shader_dir is None:
|
20 |
-
base_dir, _ = os.path.split(os.path.realpath(__file__))
|
21 |
-
self.shader_dir = os.path.join(base_dir, 'shaders')
|
22 |
-
|
23 |
-
def get_program(self, vertex_shader, fragment_shader,
|
24 |
-
geometry_shader=None, defines=None):
|
25 |
-
"""Get a program via a list of shader files to include in the program.
|
26 |
-
|
27 |
-
Parameters
|
28 |
-
----------
|
29 |
-
vertex_shader : str
|
30 |
-
The vertex shader filename.
|
31 |
-
fragment_shader : str
|
32 |
-
The fragment shader filename.
|
33 |
-
geometry_shader : str
|
34 |
-
The geometry shader filename.
|
35 |
-
defines : dict
|
36 |
-
Defines and their values for the shader.
|
37 |
-
|
38 |
-
Returns
|
39 |
-
-------
|
40 |
-
program : :class:`.ShaderProgram`
|
41 |
-
The program.
|
42 |
-
"""
|
43 |
-
shader_names = []
|
44 |
-
if defines is None:
|
45 |
-
defines = {}
|
46 |
-
shader_filenames = [
|
47 |
-
x for x in [vertex_shader, fragment_shader, geometry_shader]
|
48 |
-
if x is not None
|
49 |
-
]
|
50 |
-
for fn in shader_filenames:
|
51 |
-
if fn is None:
|
52 |
-
continue
|
53 |
-
_, name = os.path.split(fn)
|
54 |
-
shader_names.append(name)
|
55 |
-
cid = OpenGL.contextdata.getContext()
|
56 |
-
key = tuple([cid] + sorted(
|
57 |
-
[(s,1) for s in shader_names] + [(d, defines[d]) for d in defines]
|
58 |
-
))
|
59 |
-
|
60 |
-
if key not in self._program_cache:
|
61 |
-
shader_filenames = [
|
62 |
-
os.path.join(self.shader_dir, fn) for fn in shader_filenames
|
63 |
-
]
|
64 |
-
if len(shader_filenames) == 2:
|
65 |
-
shader_filenames.append(None)
|
66 |
-
vs, fs, gs = shader_filenames
|
67 |
-
self._program_cache[key] = ShaderProgram(
|
68 |
-
vertex_shader=vs, fragment_shader=fs,
|
69 |
-
geometry_shader=gs, defines=defines
|
70 |
-
)
|
71 |
-
return self._program_cache[key]
|
72 |
-
|
73 |
-
def clear(self):
|
74 |
-
for key in self._program_cache:
|
75 |
-
self._program_cache[key].delete()
|
76 |
-
self._program_cache = {}
|
77 |
-
|
78 |
-
|
79 |
-
class ShaderProgram(object):
|
80 |
-
"""A thin wrapper about OpenGL shader programs that supports easy creation,
|
81 |
-
binding, and uniform-setting.
|
82 |
-
|
83 |
-
Parameters
|
84 |
-
----------
|
85 |
-
vertex_shader : str
|
86 |
-
The vertex shader filename.
|
87 |
-
fragment_shader : str
|
88 |
-
The fragment shader filename.
|
89 |
-
geometry_shader : str
|
90 |
-
The geometry shader filename.
|
91 |
-
defines : dict
|
92 |
-
Defines and their values for the shader.
|
93 |
-
"""
|
94 |
-
|
95 |
-
def __init__(self, vertex_shader, fragment_shader,
|
96 |
-
geometry_shader=None, defines=None):
|
97 |
-
|
98 |
-
self.vertex_shader = vertex_shader
|
99 |
-
self.fragment_shader = fragment_shader
|
100 |
-
self.geometry_shader = geometry_shader
|
101 |
-
|
102 |
-
self.defines = defines
|
103 |
-
if self.defines is None:
|
104 |
-
self.defines = {}
|
105 |
-
|
106 |
-
self._program_id = None
|
107 |
-
self._vao_id = None # PYOPENGL BUG
|
108 |
-
|
109 |
-
# DEBUG
|
110 |
-
# self._unif_map = {}
|
111 |
-
|
112 |
-
def _add_to_context(self):
|
113 |
-
if self._program_id is not None:
|
114 |
-
raise ValueError('Shader program already in context')
|
115 |
-
shader_ids = []
|
116 |
-
|
117 |
-
# Load vert shader
|
118 |
-
shader_ids.append(gl_shader_utils.compileShader(
|
119 |
-
self._load(self.vertex_shader), GL_VERTEX_SHADER)
|
120 |
-
)
|
121 |
-
# Load frag shader
|
122 |
-
shader_ids.append(gl_shader_utils.compileShader(
|
123 |
-
self._load(self.fragment_shader), GL_FRAGMENT_SHADER)
|
124 |
-
)
|
125 |
-
# Load geometry shader
|
126 |
-
if self.geometry_shader is not None:
|
127 |
-
shader_ids.append(gl_shader_utils.compileShader(
|
128 |
-
self._load(self.geometry_shader), GL_GEOMETRY_SHADER)
|
129 |
-
)
|
130 |
-
|
131 |
-
# Bind empty VAO PYOPENGL BUG
|
132 |
-
if self._vao_id is None:
|
133 |
-
self._vao_id = glGenVertexArrays(1)
|
134 |
-
glBindVertexArray(self._vao_id)
|
135 |
-
|
136 |
-
# Compile program
|
137 |
-
self._program_id = gl_shader_utils.compileProgram(*shader_ids)
|
138 |
-
|
139 |
-
# Unbind empty VAO PYOPENGL BUG
|
140 |
-
glBindVertexArray(0)
|
141 |
-
|
142 |
-
def _in_context(self):
|
143 |
-
return self._program_id is not None
|
144 |
-
|
145 |
-
def _remove_from_context(self):
|
146 |
-
if self._program_id is not None:
|
147 |
-
glDeleteProgram(self._program_id)
|
148 |
-
glDeleteVertexArrays(1, [self._vao_id])
|
149 |
-
self._program_id = None
|
150 |
-
self._vao_id = None
|
151 |
-
|
152 |
-
def _load(self, shader_filename):
|
153 |
-
path, _ = os.path.split(shader_filename)
|
154 |
-
|
155 |
-
with open(shader_filename) as f:
|
156 |
-
text = f.read()
|
157 |
-
|
158 |
-
def ifdef(matchobj):
|
159 |
-
if matchobj.group(1) in self.defines:
|
160 |
-
return '#if 1'
|
161 |
-
else:
|
162 |
-
return '#if 0'
|
163 |
-
|
164 |
-
def ifndef(matchobj):
|
165 |
-
if matchobj.group(1) in self.defines:
|
166 |
-
return '#if 0'
|
167 |
-
else:
|
168 |
-
return '#if 1'
|
169 |
-
|
170 |
-
ifdef_regex = re.compile(
|
171 |
-
'#ifdef\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*$', re.MULTILINE
|
172 |
-
)
|
173 |
-
ifndef_regex = re.compile(
|
174 |
-
'#ifndef\\s+([a-zA-Z_][a-zA-Z_0-9]*)\\s*$', re.MULTILINE
|
175 |
-
)
|
176 |
-
text = re.sub(ifdef_regex, ifdef, text)
|
177 |
-
text = re.sub(ifndef_regex, ifndef, text)
|
178 |
-
|
179 |
-
for define in self.defines:
|
180 |
-
value = str(self.defines[define])
|
181 |
-
text = text.replace(define, value)
|
182 |
-
|
183 |
-
return text
|
184 |
-
|
185 |
-
def _bind(self):
|
186 |
-
"""Bind this shader program to the current OpenGL context.
|
187 |
-
"""
|
188 |
-
if self._program_id is None:
|
189 |
-
raise ValueError('Cannot bind program that is not in context')
|
190 |
-
# glBindVertexArray(self._vao_id)
|
191 |
-
glUseProgram(self._program_id)
|
192 |
-
|
193 |
-
def _unbind(self):
|
194 |
-
"""Unbind this shader program from the current OpenGL context.
|
195 |
-
"""
|
196 |
-
glUseProgram(0)
|
197 |
-
|
198 |
-
def delete(self):
|
199 |
-
"""Delete this shader program from the current OpenGL context.
|
200 |
-
"""
|
201 |
-
self._remove_from_context()
|
202 |
-
|
203 |
-
def set_uniform(self, name, value, unsigned=False):
|
204 |
-
"""Set a uniform value in the current shader program.
|
205 |
-
|
206 |
-
Parameters
|
207 |
-
----------
|
208 |
-
name : str
|
209 |
-
Name of the uniform to set.
|
210 |
-
value : int, float, or ndarray
|
211 |
-
Value to set the uniform to.
|
212 |
-
unsigned : bool
|
213 |
-
If True, ints will be treated as unsigned values.
|
214 |
-
"""
|
215 |
-
try:
|
216 |
-
# DEBUG
|
217 |
-
# self._unif_map[name] = 1, (1,)
|
218 |
-
loc = glGetUniformLocation(self._program_id, name)
|
219 |
-
|
220 |
-
if loc == -1:
|
221 |
-
raise ValueError('Invalid shader variable: {}'.format(name))
|
222 |
-
|
223 |
-
if isinstance(value, np.ndarray):
|
224 |
-
# DEBUG
|
225 |
-
# self._unif_map[name] = value.size, value.shape
|
226 |
-
if value.ndim == 1:
|
227 |
-
if (np.issubdtype(value.dtype, np.unsignedinteger) or
|
228 |
-
unsigned):
|
229 |
-
dtype = 'u'
|
230 |
-
value = value.astype(np.uint32)
|
231 |
-
elif np.issubdtype(value.dtype, np.integer):
|
232 |
-
dtype = 'i'
|
233 |
-
value = value.astype(np.int32)
|
234 |
-
else:
|
235 |
-
dtype = 'f'
|
236 |
-
value = value.astype(np.float32)
|
237 |
-
self._FUNC_MAP[(value.shape[0], dtype)](loc, 1, value)
|
238 |
-
else:
|
239 |
-
self._FUNC_MAP[(value.shape[0], value.shape[1])](
|
240 |
-
loc, 1, GL_TRUE, value
|
241 |
-
)
|
242 |
-
|
243 |
-
# Call correct uniform function
|
244 |
-
elif isinstance(value, float):
|
245 |
-
glUniform1f(loc, value)
|
246 |
-
elif isinstance(value, int):
|
247 |
-
if unsigned:
|
248 |
-
glUniform1ui(loc, value)
|
249 |
-
else:
|
250 |
-
glUniform1i(loc, value)
|
251 |
-
elif isinstance(value, bool):
|
252 |
-
if unsigned:
|
253 |
-
glUniform1ui(loc, int(value))
|
254 |
-
else:
|
255 |
-
glUniform1i(loc, int(value))
|
256 |
-
else:
|
257 |
-
raise ValueError('Invalid data type')
|
258 |
-
except Exception:
|
259 |
-
pass
|
260 |
-
|
261 |
-
_FUNC_MAP = {
|
262 |
-
(1,'u'): glUniform1uiv,
|
263 |
-
(2,'u'): glUniform2uiv,
|
264 |
-
(3,'u'): glUniform3uiv,
|
265 |
-
(4,'u'): glUniform4uiv,
|
266 |
-
(1,'i'): glUniform1iv,
|
267 |
-
(2,'i'): glUniform2iv,
|
268 |
-
(3,'i'): glUniform3iv,
|
269 |
-
(4,'i'): glUniform4iv,
|
270 |
-
(1,'f'): glUniform1fv,
|
271 |
-
(2,'f'): glUniform2fv,
|
272 |
-
(3,'f'): glUniform3fv,
|
273 |
-
(4,'f'): glUniform4fv,
|
274 |
-
(2,2): glUniformMatrix2fv,
|
275 |
-
(2,3): glUniformMatrix2x3fv,
|
276 |
-
(2,4): glUniformMatrix2x4fv,
|
277 |
-
(3,2): glUniformMatrix3x2fv,
|
278 |
-
(3,3): glUniformMatrix3fv,
|
279 |
-
(3,4): glUniformMatrix3x4fv,
|
280 |
-
(4,2): glUniformMatrix4x2fv,
|
281 |
-
(4,3): glUniformMatrix4x3fv,
|
282 |
-
(4,4): glUniformMatrix4fv,
|
283 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AIGC-Audio/AudioGPT/text_to_speech/utils/audio/rnnoise.py
DELETED
@@ -1,48 +0,0 @@
|
|
1 |
-
# rnnoise.py, requirements: ffmpeg, sox, rnnoise, python
|
2 |
-
import os
|
3 |
-
import subprocess
|
4 |
-
|
5 |
-
INSTALL_STR = """
|
6 |
-
RNNoise library not found. Please install RNNoise (https://github.com/xiph/rnnoise) to $REPO/rnnoise:
|
7 |
-
sudo apt-get install -y autoconf automake libtool ffmpeg sox
|
8 |
-
git clone https://github.com/xiph/rnnoise.git
|
9 |
-
rm -rf rnnoise/.git
|
10 |
-
cd rnnoise
|
11 |
-
./autogen.sh && ./configure && make
|
12 |
-
cd ..
|
13 |
-
"""
|
14 |
-
|
15 |
-
|
16 |
-
def rnnoise(filename, out_fn=None, verbose=False, out_sample_rate=22050):
|
17 |
-
assert os.path.exists('./rnnoise/examples/rnnoise_demo'), INSTALL_STR
|
18 |
-
if out_fn is None:
|
19 |
-
out_fn = f"{filename[:-4]}.denoised.wav"
|
20 |
-
out_48k_fn = f"{out_fn}.48000.wav"
|
21 |
-
tmp0_fn = f"{out_fn}.0.wav"
|
22 |
-
tmp1_fn = f"{out_fn}.1.wav"
|
23 |
-
tmp2_fn = f"{out_fn}.2.raw"
|
24 |
-
tmp3_fn = f"{out_fn}.3.raw"
|
25 |
-
if verbose:
|
26 |
-
print("Pre-processing audio...") # wav to pcm raw
|
27 |
-
subprocess.check_call(
|
28 |
-
f'sox "{filename}" -G -r48000 "{tmp0_fn}"', shell=True, stdin=subprocess.PIPE) # convert to raw
|
29 |
-
subprocess.check_call(
|
30 |
-
f'sox -v 0.95 "{tmp0_fn}" "{tmp1_fn}"', shell=True, stdin=subprocess.PIPE) # convert to raw
|
31 |
-
subprocess.check_call(
|
32 |
-
f'ffmpeg -y -i "{tmp1_fn}" -loglevel quiet -f s16le -ac 1 -ar 48000 "{tmp2_fn}"',
|
33 |
-
shell=True, stdin=subprocess.PIPE) # convert to raw
|
34 |
-
if verbose:
|
35 |
-
print("Applying rnnoise algorithm to audio...") # rnnoise
|
36 |
-
subprocess.check_call(
|
37 |
-
f'./rnnoise/examples/rnnoise_demo "{tmp2_fn}" "{tmp3_fn}"', shell=True)
|
38 |
-
|
39 |
-
if verbose:
|
40 |
-
print("Post-processing audio...") # pcm raw to wav
|
41 |
-
if filename == out_fn:
|
42 |
-
subprocess.check_call(f'rm -f "{out_fn}"', shell=True)
|
43 |
-
subprocess.check_call(
|
44 |
-
f'sox -t raw -r 48000 -b 16 -e signed-integer -c 1 "{tmp3_fn}" "{out_48k_fn}"', shell=True)
|
45 |
-
subprocess.check_call(f'sox "{out_48k_fn}" -G -r{out_sample_rate} "{out_fn}"', shell=True)
|
46 |
-
subprocess.check_call(f'rm -f "{tmp0_fn}" "{tmp1_fn}" "{tmp2_fn}" "{tmp3_fn}" "{out_48k_fn}"', shell=True)
|
47 |
-
if verbose:
|
48 |
-
print("Audio-filtering completed!")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Abhilashvj/planogram-compliance/utils/flask_rest_api/README.md
DELETED
@@ -1,73 +0,0 @@
|
|
1 |
-
# Flask REST API
|
2 |
-
|
3 |
-
[REST](https://en.wikipedia.org/wiki/Representational_state_transfer) [API](https://en.wikipedia.org/wiki/API)s are
|
4 |
-
commonly used to expose Machine Learning (ML) models to other services. This folder contains an example REST API
|
5 |
-
created using Flask to expose the YOLOv5s model from [PyTorch Hub](https://pytorch.org/hub/ultralytics_yolov5/).
|
6 |
-
|
7 |
-
## Requirements
|
8 |
-
|
9 |
-
[Flask](https://palletsprojects.com/p/flask/) is required. Install with:
|
10 |
-
|
11 |
-
```shell
|
12 |
-
$ pip install Flask
|
13 |
-
```
|
14 |
-
|
15 |
-
## Run
|
16 |
-
|
17 |
-
After Flask installation run:
|
18 |
-
|
19 |
-
```shell
|
20 |
-
$ python3 restapi.py --port 5000
|
21 |
-
```
|
22 |
-
|
23 |
-
Then use [curl](https://curl.se/) to perform a request:
|
24 |
-
|
25 |
-
```shell
|
26 |
-
$ curl -X POST -F [email protected] 'http://localhost:5000/v1/object-detection/yolov5s'
|
27 |
-
```
|
28 |
-
|
29 |
-
The model inference results are returned as a JSON response:
|
30 |
-
|
31 |
-
```json
|
32 |
-
[
|
33 |
-
{
|
34 |
-
"class": 0,
|
35 |
-
"confidence": 0.8900438547,
|
36 |
-
"height": 0.9318675399,
|
37 |
-
"name": "person",
|
38 |
-
"width": 0.3264600933,
|
39 |
-
"xcenter": 0.7438579798,
|
40 |
-
"ycenter": 0.5207948685
|
41 |
-
},
|
42 |
-
{
|
43 |
-
"class": 0,
|
44 |
-
"confidence": 0.8440024257,
|
45 |
-
"height": 0.7155083418,
|
46 |
-
"name": "person",
|
47 |
-
"width": 0.6546785235,
|
48 |
-
"xcenter": 0.427829951,
|
49 |
-
"ycenter": 0.6334488392
|
50 |
-
},
|
51 |
-
{
|
52 |
-
"class": 27,
|
53 |
-
"confidence": 0.3771208823,
|
54 |
-
"height": 0.3902671337,
|
55 |
-
"name": "tie",
|
56 |
-
"width": 0.0696444362,
|
57 |
-
"xcenter": 0.3675483763,
|
58 |
-
"ycenter": 0.7991207838
|
59 |
-
},
|
60 |
-
{
|
61 |
-
"class": 27,
|
62 |
-
"confidence": 0.3527112305,
|
63 |
-
"height": 0.1540903747,
|
64 |
-
"name": "tie",
|
65 |
-
"width": 0.0336618312,
|
66 |
-
"xcenter": 0.7814827561,
|
67 |
-
"ycenter": 0.5065554976
|
68 |
-
}
|
69 |
-
]
|
70 |
-
```
|
71 |
-
|
72 |
-
An example python script to perform inference using [requests](https://docs.python-requests.org/en/master/) is given
|
73 |
-
in `example_request.py`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AchyuthGamer/OpenGPT/g4f/Provider/deprecated/ChatgptLogin.py
DELETED
@@ -1,74 +0,0 @@
|
|
1 |
-
from __future__ import annotations
|
2 |
-
|
3 |
-
import os, re
|
4 |
-
from aiohttp import ClientSession
|
5 |
-
|
6 |
-
from ..base_provider import AsyncProvider, format_prompt
|
7 |
-
|
8 |
-
|
9 |
-
class ChatgptLogin(AsyncProvider):
|
10 |
-
url = "https://opchatgpts.net"
|
11 |
-
supports_gpt_35_turbo = True
|
12 |
-
working = True
|
13 |
-
_nonce = None
|
14 |
-
|
15 |
-
@classmethod
|
16 |
-
async def create_async(
|
17 |
-
cls,
|
18 |
-
model: str,
|
19 |
-
messages: list[dict[str, str]],
|
20 |
-
**kwargs
|
21 |
-
) -> str:
|
22 |
-
headers = {
|
23 |
-
"User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36",
|
24 |
-
"Accept" : "*/*",
|
25 |
-
"Accept-language" : "en,fr-FR;q=0.9,fr;q=0.8,es-ES;q=0.7,es;q=0.6,en-US;q=0.5,am;q=0.4,de;q=0.3",
|
26 |
-
"Origin" : "https://opchatgpts.net",
|
27 |
-
"Alt-Used" : "opchatgpts.net",
|
28 |
-
"Referer" : "https://opchatgpts.net/chatgpt-free-use/",
|
29 |
-
"Sec-Fetch-Dest" : "empty",
|
30 |
-
"Sec-Fetch-Mode" : "cors",
|
31 |
-
"Sec-Fetch-Site" : "same-origin",
|
32 |
-
}
|
33 |
-
async with ClientSession(
|
34 |
-
headers=headers
|
35 |
-
) as session:
|
36 |
-
if not cls._nonce:
|
37 |
-
async with session.get(
|
38 |
-
"https://opchatgpts.net/chatgpt-free-use/",
|
39 |
-
params={"id": os.urandom(6).hex()},
|
40 |
-
) as response:
|
41 |
-
result = re.search(r'data-nonce="(.*?)"', await response.text())
|
42 |
-
if not result:
|
43 |
-
raise RuntimeError("No nonce value")
|
44 |
-
cls._nonce = result.group(1)
|
45 |
-
data = {
|
46 |
-
"_wpnonce": cls._nonce,
|
47 |
-
"post_id": 28,
|
48 |
-
"url": "https://opchatgpts.net/chatgpt-free-use",
|
49 |
-
"action": "wpaicg_chat_shortcode_message",
|
50 |
-
"message": format_prompt(messages),
|
51 |
-
"bot_id": 0
|
52 |
-
}
|
53 |
-
async with session.post("https://opchatgpts.net/wp-admin/admin-ajax.php", data=data) as response:
|
54 |
-
response.raise_for_status()
|
55 |
-
data = await response.json()
|
56 |
-
if "data" in data:
|
57 |
-
return data["data"]
|
58 |
-
elif "msg" in data:
|
59 |
-
raise RuntimeError(data["msg"])
|
60 |
-
else:
|
61 |
-
raise RuntimeError(f"Response: {data}")
|
62 |
-
|
63 |
-
|
64 |
-
@classmethod
|
65 |
-
@property
|
66 |
-
def params(cls):
|
67 |
-
params = [
|
68 |
-
("model", "str"),
|
69 |
-
("messages", "list[dict[str, str]]"),
|
70 |
-
("stream", "bool"),
|
71 |
-
("temperature", "float"),
|
72 |
-
]
|
73 |
-
param = ", ".join([": ".join(p) for p in params])
|
74 |
-
return f"g4f.provider.{cls.__name__} supports: ({param})"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AgentVerse/agentVerse/agentverse/agents/tasksolving_agent/role_assigner.py
DELETED
@@ -1,88 +0,0 @@
|
|
1 |
-
from __future__ import annotations
|
2 |
-
|
3 |
-
import asyncio
|
4 |
-
from colorama import Fore
|
5 |
-
|
6 |
-
from agentverse.logging import get_logger
|
7 |
-
import bdb
|
8 |
-
from string import Template
|
9 |
-
from typing import TYPE_CHECKING, List
|
10 |
-
|
11 |
-
from agentverse.message import RoleAssignerMessage, Message
|
12 |
-
|
13 |
-
from agentverse.agents import agent_registry
|
14 |
-
from agentverse.agents.base import BaseAgent
|
15 |
-
|
16 |
-
|
17 |
-
logger = get_logger()
|
18 |
-
|
19 |
-
|
20 |
-
@agent_registry.register("role_assigner")
|
21 |
-
class RoleAssignerAgent(BaseAgent):
|
22 |
-
def step(
|
23 |
-
self, advice: str, task_description: str, cnt_critic_agents: int
|
24 |
-
) -> RoleAssignerMessage:
|
25 |
-
logger.debug("", self.name, Fore.MAGENTA)
|
26 |
-
prepend_prompt, append_prompt = self.get_all_prompts(
|
27 |
-
advice=advice,
|
28 |
-
task_description=task_description,
|
29 |
-
cnt_critic_agents=cnt_critic_agents,
|
30 |
-
)
|
31 |
-
history = self.memory.to_messages(self.name)
|
32 |
-
parsed_response = None
|
33 |
-
for i in range(self.max_retry):
|
34 |
-
try:
|
35 |
-
response = self.llm.generate_response(
|
36 |
-
prepend_prompt, history, append_prompt
|
37 |
-
)
|
38 |
-
parsed_response = self.output_parser.parse(response)
|
39 |
-
if len(parsed_response) < cnt_critic_agents:
|
40 |
-
logger.warn(
|
41 |
-
f"Number of generate roles ({len(parsed_response)}) and number of group members ({cnt_critic_agents}) do not match."
|
42 |
-
)
|
43 |
-
logger.warn("Retrying...")
|
44 |
-
continue
|
45 |
-
break
|
46 |
-
except (KeyboardInterrupt, bdb.BdbQuit):
|
47 |
-
raise
|
48 |
-
except Exception as e:
|
49 |
-
logger.error(e)
|
50 |
-
logger.warn("Retrying...")
|
51 |
-
continue
|
52 |
-
|
53 |
-
if parsed_response is None:
|
54 |
-
logger.error(f"{self.name} failed to generate valid response.")
|
55 |
-
|
56 |
-
message = RoleAssignerMessage(
|
57 |
-
content=parsed_response, sender=self.name, sender_agent=self
|
58 |
-
)
|
59 |
-
return message
|
60 |
-
|
61 |
-
async def astep(self, env_description: str = "") -> RoleAssignerMessage:
|
62 |
-
"""Asynchronous version of step"""
|
63 |
-
pass
|
64 |
-
|
65 |
-
def _fill_prompt_template(
|
66 |
-
self, advice, task_description: str, cnt_critic_agents: int
|
67 |
-
) -> str:
|
68 |
-
"""Fill the placeholders in the prompt template
|
69 |
-
|
70 |
-
In the role_assigner agent, three placeholders are supported:
|
71 |
-
- ${task_description}
|
72 |
-
- ${cnt_critic_agnets}
|
73 |
-
- ${advice}
|
74 |
-
"""
|
75 |
-
input_arguments = {
|
76 |
-
"task_description": task_description,
|
77 |
-
"cnt_critic_agents": cnt_critic_agents,
|
78 |
-
"advice": advice,
|
79 |
-
}
|
80 |
-
return Template(self.prompt_template).safe_substitute(input_arguments)
|
81 |
-
|
82 |
-
def add_message_to_memory(self, messages: List[Message]) -> None:
|
83 |
-
self.memory.add_message(messages)
|
84 |
-
|
85 |
-
def reset(self) -> None:
|
86 |
-
"""Reset the agent"""
|
87 |
-
self.memory.reset()
|
88 |
-
# TODO: reset receiver
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AgentVerse/agentVerse/agentverse/environments/simulation_env/basic.py
DELETED
@@ -1,101 +0,0 @@
|
|
1 |
-
import asyncio
|
2 |
-
|
3 |
-
# import logging
|
4 |
-
from agentverse.logging import get_logger
|
5 |
-
from typing import Any, Dict, List
|
6 |
-
|
7 |
-
# from agentverse.agents.agent import Agent
|
8 |
-
from agentverse.agents.simulation_agent.conversation import BaseAgent
|
9 |
-
|
10 |
-
# from agentverse.environments.simulation_env.rules.base import Rule
|
11 |
-
from agentverse.environments.simulation_env.rules.base import SimulationRule as Rule
|
12 |
-
from agentverse.message import Message
|
13 |
-
|
14 |
-
logger = get_logger()
|
15 |
-
|
16 |
-
from .. import env_registry as EnvironmentRegistry
|
17 |
-
from ..base import BaseEnvironment
|
18 |
-
|
19 |
-
|
20 |
-
@EnvironmentRegistry.register("sim-basic")
|
21 |
-
class BasicEnvironment(BaseEnvironment):
|
22 |
-
"""
|
23 |
-
A basic environment implementing the logic of conversation.
|
24 |
-
|
25 |
-
Args:
|
26 |
-
agents: List of agents
|
27 |
-
rule: Rule for the environment
|
28 |
-
max_turns: Maximum number of turns
|
29 |
-
cnt_turn: Current turn number
|
30 |
-
last_messages: Messages from last turn
|
31 |
-
rule_params: Variables set by the rule
|
32 |
-
"""
|
33 |
-
|
34 |
-
agents: List[BaseAgent]
|
35 |
-
rule: Rule
|
36 |
-
max_turns: int = 10
|
37 |
-
cnt_turn: int = 0
|
38 |
-
last_messages: List[Message] = []
|
39 |
-
rule_params: Dict = {}
|
40 |
-
|
41 |
-
def __init__(self, rule, **kwargs):
|
42 |
-
rule_config = rule
|
43 |
-
order_config = rule_config.get("order", {"type": "sequential"})
|
44 |
-
visibility_config = rule_config.get("visibility", {"type": "all"})
|
45 |
-
selector_config = rule_config.get("selector", {"type": "basic"})
|
46 |
-
updater_config = rule_config.get("updater", {"type": "basic"})
|
47 |
-
describer_config = rule_config.get("describer", {"type": "basic"})
|
48 |
-
rule = Rule(
|
49 |
-
order_config,
|
50 |
-
visibility_config,
|
51 |
-
selector_config,
|
52 |
-
updater_config,
|
53 |
-
describer_config,
|
54 |
-
)
|
55 |
-
super().__init__(rule=rule, **kwargs)
|
56 |
-
|
57 |
-
async def step(self) -> List[Message]:
|
58 |
-
"""Run one step of the environment"""
|
59 |
-
|
60 |
-
# Get the next agent index
|
61 |
-
agent_ids = self.rule.get_next_agent_idx(self)
|
62 |
-
|
63 |
-
# Generate current environment description
|
64 |
-
env_descriptions = self.rule.get_env_description(self)
|
65 |
-
|
66 |
-
# Generate the next message
|
67 |
-
messages = await asyncio.gather(
|
68 |
-
*[self.agents[i].astep(env_descriptions[i]) for i in agent_ids]
|
69 |
-
)
|
70 |
-
|
71 |
-
# Some rules will select certain messages from all the messages
|
72 |
-
selected_messages = self.rule.select_message(self, messages)
|
73 |
-
self.last_messages = selected_messages
|
74 |
-
self.print_messages(selected_messages)
|
75 |
-
|
76 |
-
# Update the memory of the agents
|
77 |
-
self.rule.update_memory(self)
|
78 |
-
|
79 |
-
# Update the set of visible agents for each agent
|
80 |
-
self.rule.update_visible_agents(self)
|
81 |
-
|
82 |
-
self.cnt_turn += 1
|
83 |
-
|
84 |
-
return selected_messages
|
85 |
-
|
86 |
-
def print_messages(self, messages: List[Message]) -> None:
|
87 |
-
for message in messages:
|
88 |
-
if message is not None:
|
89 |
-
# logging.info(f"{message.sender}: {message.content}")
|
90 |
-
logger.info(f"{message.sender}: {message.content}")
|
91 |
-
|
92 |
-
def reset(self) -> None:
|
93 |
-
"""Reset the environment"""
|
94 |
-
self.cnt_turn = 0
|
95 |
-
self.rule.reset()
|
96 |
-
for agent in self.agents:
|
97 |
-
agent.reset()
|
98 |
-
|
99 |
-
def is_done(self) -> bool:
|
100 |
-
"""Check if the environment is done"""
|
101 |
-
return self.cnt_turn >= self.max_turns
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AhmedMagdy7/My_paper_space/README.md
DELETED
@@ -1,13 +0,0 @@
|
|
1 |
-
---
|
2 |
-
title: My Paper Space
|
3 |
-
emoji: 🏃
|
4 |
-
colorFrom: purple
|
5 |
-
colorTo: gray
|
6 |
-
sdk: gradio
|
7 |
-
sdk_version: 4.1.2
|
8 |
-
app_file: app.py
|
9 |
-
pinned: false
|
10 |
-
license: apache-2.0
|
11 |
-
---
|
12 |
-
|
13 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AkashKhamkar/Job_Search_Engine/skill_list.py
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
skills = ['HTML','Cryptography' , 'Data structures' ,'Blockchain' ,'Cryptography' ,'Smart contracts' ,'Outlook','Netbeans','python','JAVA','Networking','DML','Rest Web Services','Windows','MS Power Point.','MS-Access','technical assistance.','SAP','UNIX','Citrix Xen Server','Web Application testing','Cyara','Linux','MICROSOFT','Nagios','Software Testing','GIT','Eclipse','Sonar Qube''C#.net','Apache','Data Modeling','Database','MySQL','Angular Js','Networking','AWS','java servlet','Jquery','Selenium','Selenium Webdriver','NoSQL','GWT','CSS','Computer','SQL Server 2010','Web Development','Internet Of Things','Windows/XP','R Studio','network engineers','Java.','MS OFFICE','Testing','CCNA','ipsec','ANDROID','HSRP','CPP','Application Designer','PowerShell','MS Word','Ms-Access', "NetBeans",'Cloud Computing','OpenShit','Web Designing','Jdeveloper','computer and firesafety','HTML','Windows and Linux','CISCO','Azure','SAS','Sql','SQL developer','Computer Networks','php','Ansible','Excel','Apache Tomcat','Ansible','Bootstrap','JavaScript','SQL','VB.net','APPLICATION SOFTWARE','Micro Services','Java Script','Eclipse IDE.','Bash','Putty','SPUFI','Agile','Hacking','bgp','Invoice','AMDP.','ASP','Artificial Intelligence','Application / Software Development','mpls','Program Management','C','MS-Access','Java' ,'Kibana','Maven','Open VZ','ASP.NET','C# .NET','AWS','java script','Hibernate','routing protocols.','cricket','Automation','MySQL','Lithium','Git','GCP','JSON','Maria-DB','Spring','Socket Programming','EJB','Nexus','Html5','PostgreSQL','Ms Word and Power Point','ASP.NET','CSS 3.0','Hyper-','Servlet','PowerPoint','JMS','multicast','Windows Services','IoT','Hardware & Networking','SAPUI5','Machine Learning','TRAINING','SQL','C++','Gephi','Go Lang','AngularJs','Object Oriented Programming','Struts','Application & Web Servers: Sciencelogic (EM7)','Java/C/C++ ','M.S. OFFICE','Billing','active directory','Big data''ASP Technical specifications creation','Confidential Record Keeping','Postman','Goal Oriented & Self Motivated','VB','Content',' SAPUI5 (Primary Skill)','Mongo DB','Market Basket Analysis','Familiar with SQL','Hospitality','Web Authoring Tools HTML 5','Reporting Tools: Vportal','Network Management','Operations','Inversion of Control','MS office','Monthly patching update activity and server owner approval / RFC follow-ups.','Ajax &JQuery','rogramming :C/C++','problem solving','Functional Testing','Octopus','good at communication','angular','PL/SQL Developer','Windows XP','ospf','Powershell','work devotee','APACHE','Android Studio','exchange','Frontend HTML and .Net','DBMS','excellent in various sports like soccer','Predictive Modelling','KVM','JQuery.','ACCESS','Work on Windows 7','CRM','Selenium (Selenium IDE','RESOURCE PLANNING','PowerPoint Language: Fluent in verbal','STL)','good time management skills','DNS','than 1 year)','Accounts Payable-FI-A/P','java','Mac','IDE: Eclipse','JQuery','PHP','kannada','IT Literacy','SIEM','Highly Dedicated towards work','RDBMS: MySQL','MS OFFICE (MS excel','Ansys','Bid management','Corporate Communications','Wireshark','OpenStack','Front end/GUI Tools programming: Adobe Flex','team player','XML','Good communication - written and oral skills','Tally','TestNG','Team-Player','Database MySQL','Tolerant and Flexible to Different Situations','Data Driven','Building good relationship with people.','Marathi','Source Control Management: SVN','ADDITIONAL INFORMATION','wsus','C#','MATLAB','Oracle System upgrades','Mobile Applications','Page Object model','Microsoft Azure','Selenium','Design Patterns','Typewriting','Sql server 2005','Docker','MYSQL','Network Security','Database','Project management','D3js','Technical Experience: - Automation Testing (REST API','SQL Server','Bamboo','SAP UI5/Fiori','LINUX','people and environments.','SAP HANA','Scrum Ma','7','Service Virtualization)','Computer: Proficient in Windows','WAF','Git','Banking','Relay server.','Sauce Labs','5.0 (E)','Java & J2EE','PL-SQL programming','Programming VB','NetBeans','Computer Hardware','great at taking','Sql Server','Catia V6','Editing','SQL.','good communication and listening skills.','Mobile Testing','McAfee ESM','PMP trained six sigma yellow belt',' Linux','project manager','putty',' Windows','R studio','Capable and Hardworking','Microsoft Visual Studio 2010','Ubuntu Linux','Ajax.','Html','Splunk','Framework & tools :ADF','Syslog sender','tcl','Basic Computers knowledge','ADOBE PHOTOSHOP','Css','ERP SAP R/3 in 4.7','Python','Database Management System','HttpClient','Efficient Individual and Team Player','Oracle 10g','css','Tools: RADTool','Creo parametric 2.0','Jenkins','Cisco Monitoring Tools: EM7','Android','NETWORKING','10','Sublime','Mockito','Creative Team Leadership','posting.','Operating','WinSCP','Pleasing personality','AJAX','l3vpn','Clustering','Content Migration tools Metalogix and Sharegate','Project Management','Iterative Development','SVN.','Data Structures & Algorithms','Oracle','Jackson-2','4.5','SDET','Frameworks (C#) 4.0','Cucumber','Inside Sales','Jdbc','Oracle PeopleSoft','JavaScript.','EMPLOYEE RESOURCE GROUP','jQuery','Selenium Web Driver)','DNS','.net','ASP.Net with C#','sql','CA7',' C#','Good English','VBA','running','DHCP','Domain Knowledge: E-commerce','knowledge of Active Directory','SOAP Web Services','SOAP UI','Java (Preliminary)','Tomcat','ESXi','Programming','GitLab','Windows 7','Salesforce','Positive Attitude.','Technology: Multimedia','Automation Testing','Strong Analytical and logical skills','Windows 8','Software Development Life Cycle','Database SQL Server and Oracle','Unix','JSP.','Javascript','REST','Junit','Hard working with abstract thinking.','Databases and Tools Informatica Power Center','C','DDL','Spring MVC','Sentimental Analysis','and LAN/WAN.','FlexBuilder','Middleware MVC and WCF','Java','Net beans','Tortoise SVN.','SDLC Model: -Waterfall','Oracle SQL Developer','kabbadi','Core Java','PowerShell','Mysql','MongoDB','SOAP','QMF','MS Visio','CSS','Excellent conceptual and analytical skills','Good communication skills','ABAP/4','JUnit','Flexible and high adaptability to new approaches','Smart Working.','O365','ENTERPRISE','Users / Share folders creation and permission assigning.','MS Excel','ClouStack','Jira','ORM Eclipse Link','swimming','Xpeditor','CSS3','Microsoft Office','MainView','software integration','Apache Nifi','dns','SAP ABAP','R','SQL Server','QTP','Network','Web HTML']
|
2 |
-
|
3 |
-
# print(len(skills))
|
|
|
|
|
|
|
|
spaces/Akim/claudeAPI/webapi_claude.py
DELETED
@@ -1,60 +0,0 @@
|
|
1 |
-
from flask import Flask, request, jsonify
|
2 |
-
import asyncio
|
3 |
-
import aiohttp, os
|
4 |
-
|
5 |
-
|
6 |
-
app = Flask(__name__)
|
7 |
-
|
8 |
-
async def claude_new_process(prompt):
|
9 |
-
headers = {
|
10 |
-
"x-api-key": os.environ.get('API_KEY'),
|
11 |
-
"content-type": "application/json"
|
12 |
-
}
|
13 |
-
data = {
|
14 |
-
"prompt": prompt,
|
15 |
-
"model": "claude-v1.3-100k",
|
16 |
-
"max_tokens_to_sample": 1000000, #tokens (any number for the free API)
|
17 |
-
"temperature": "0.52", #you know what this is
|
18 |
-
"stopsequences": "\n\nHuman: ", #(don't touch)
|
19 |
-
}
|
20 |
-
|
21 |
-
#proxy_url = "8.219.97.248"
|
22 |
-
#proxy_port = "80"
|
23 |
-
#proxy = f'http://{proxy_url}:{proxy_port}'
|
24 |
-
|
25 |
-
async with aiohttp.ClientSession() as session:
|
26 |
-
async with session.post("https://api.anthropic.com/v1/complete", json=data, headers=headers
|
27 |
-
#, proxy=proxy
|
28 |
-
) as response:
|
29 |
-
|
30 |
-
if response.status == 200:
|
31 |
-
#print(response.status, await response.json())
|
32 |
-
return 200, await response.json()
|
33 |
-
else:
|
34 |
-
return response.status, "error"
|
35 |
-
|
36 |
-
@app.route('/api/claude', methods=['POST'])
|
37 |
-
def api_claude_new_process():
|
38 |
-
prompt = request.json['prompt']
|
39 |
-
key = request.json['password']
|
40 |
-
print(f"{prompt} {key}")
|
41 |
-
if key != os.environ.get('PASSWORD'):
|
42 |
-
return jsonify({'error': 'wrong password'}), 403
|
43 |
-
|
44 |
-
print(f"Called with prompts: {prompt}")
|
45 |
-
loop = asyncio.new_event_loop()
|
46 |
-
asyncio.set_event_loop(loop)
|
47 |
-
status_code, response = loop.run_until_complete(claude_new_process(prompt))
|
48 |
-
if status_code == 200:
|
49 |
-
print(response)
|
50 |
-
return response, 200
|
51 |
-
else:
|
52 |
-
return jsonify({'error': 'error'}), status_code
|
53 |
-
|
54 |
-
async def test():
|
55 |
-
status, response = await claude_new_process('\n\nHuman: Hello! \n\nGigachad: ')
|
56 |
-
print (response['completion'])
|
57 |
-
|
58 |
-
if __name__ == '__main__':
|
59 |
-
#asyncio.run(test())
|
60 |
-
app.run(debug=True, port='7860', host='0.0.0.0')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Alpaca233/SadTalker/predict.py
DELETED
@@ -1,192 +0,0 @@
|
|
1 |
-
"""run bash scripts/download_models.sh first to prepare the weights file"""
|
2 |
-
import os
|
3 |
-
import shutil
|
4 |
-
from argparse import Namespace
|
5 |
-
from src.utils.preprocess import CropAndExtract
|
6 |
-
from src.test_audio2coeff import Audio2Coeff
|
7 |
-
from src.facerender.animate import AnimateFromCoeff
|
8 |
-
from src.generate_batch import get_data
|
9 |
-
from src.generate_facerender_batch import get_facerender_data
|
10 |
-
from src.utils.init_path import init_path
|
11 |
-
from cog import BasePredictor, Input, Path
|
12 |
-
|
13 |
-
checkpoints = "checkpoints"
|
14 |
-
|
15 |
-
|
16 |
-
class Predictor(BasePredictor):
|
17 |
-
def setup(self):
|
18 |
-
"""Load the model into memory to make running multiple predictions efficient"""
|
19 |
-
device = "cuda"
|
20 |
-
|
21 |
-
|
22 |
-
sadtalker_paths = init_path(checkpoints,os.path.join("src","config"))
|
23 |
-
|
24 |
-
# init model
|
25 |
-
self.preprocess_model = CropAndExtract(sadtalker_paths, device
|
26 |
-
)
|
27 |
-
|
28 |
-
self.audio_to_coeff = Audio2Coeff(
|
29 |
-
sadtalker_paths,
|
30 |
-
device,
|
31 |
-
)
|
32 |
-
|
33 |
-
self.animate_from_coeff = {
|
34 |
-
"full": AnimateFromCoeff(
|
35 |
-
sadtalker_paths,
|
36 |
-
device,
|
37 |
-
),
|
38 |
-
"others": AnimateFromCoeff(
|
39 |
-
sadtalker_paths,
|
40 |
-
device,
|
41 |
-
),
|
42 |
-
}
|
43 |
-
|
44 |
-
def predict(
|
45 |
-
self,
|
46 |
-
source_image: Path = Input(
|
47 |
-
description="Upload the source image, it can be video.mp4 or picture.png",
|
48 |
-
),
|
49 |
-
driven_audio: Path = Input(
|
50 |
-
description="Upload the driven audio, accepts .wav and .mp4 file",
|
51 |
-
),
|
52 |
-
enhancer: str = Input(
|
53 |
-
description="Choose a face enhancer",
|
54 |
-
choices=["gfpgan", "RestoreFormer"],
|
55 |
-
default="gfpgan",
|
56 |
-
),
|
57 |
-
preprocess: str = Input(
|
58 |
-
description="how to preprocess the images",
|
59 |
-
choices=["crop", "resize", "full"],
|
60 |
-
default="full",
|
61 |
-
),
|
62 |
-
ref_eyeblink: Path = Input(
|
63 |
-
description="path to reference video providing eye blinking",
|
64 |
-
default=None,
|
65 |
-
),
|
66 |
-
ref_pose: Path = Input(
|
67 |
-
description="path to reference video providing pose",
|
68 |
-
default=None,
|
69 |
-
),
|
70 |
-
still: bool = Input(
|
71 |
-
description="can crop back to the original videos for the full body aniamtion when preprocess is full",
|
72 |
-
default=True,
|
73 |
-
),
|
74 |
-
) -> Path:
|
75 |
-
"""Run a single prediction on the model"""
|
76 |
-
|
77 |
-
animate_from_coeff = (
|
78 |
-
self.animate_from_coeff["full"]
|
79 |
-
if preprocess == "full"
|
80 |
-
else self.animate_from_coeff["others"]
|
81 |
-
)
|
82 |
-
|
83 |
-
args = load_default()
|
84 |
-
args.pic_path = str(source_image)
|
85 |
-
args.audio_path = str(driven_audio)
|
86 |
-
device = "cuda"
|
87 |
-
args.still = still
|
88 |
-
args.ref_eyeblink = None if ref_eyeblink is None else str(ref_eyeblink)
|
89 |
-
args.ref_pose = None if ref_pose is None else str(ref_pose)
|
90 |
-
|
91 |
-
# crop image and extract 3dmm from image
|
92 |
-
results_dir = "results"
|
93 |
-
if os.path.exists(results_dir):
|
94 |
-
shutil.rmtree(results_dir)
|
95 |
-
os.makedirs(results_dir)
|
96 |
-
first_frame_dir = os.path.join(results_dir, "first_frame_dir")
|
97 |
-
os.makedirs(first_frame_dir)
|
98 |
-
|
99 |
-
print("3DMM Extraction for source image")
|
100 |
-
first_coeff_path, crop_pic_path, crop_info = self.preprocess_model.generate(
|
101 |
-
args.pic_path, first_frame_dir, preprocess, source_image_flag=True
|
102 |
-
)
|
103 |
-
if first_coeff_path is None:
|
104 |
-
print("Can't get the coeffs of the input")
|
105 |
-
return
|
106 |
-
|
107 |
-
if ref_eyeblink is not None:
|
108 |
-
ref_eyeblink_videoname = os.path.splitext(os.path.split(ref_eyeblink)[-1])[
|
109 |
-
0
|
110 |
-
]
|
111 |
-
ref_eyeblink_frame_dir = os.path.join(results_dir, ref_eyeblink_videoname)
|
112 |
-
os.makedirs(ref_eyeblink_frame_dir, exist_ok=True)
|
113 |
-
print("3DMM Extraction for the reference video providing eye blinking")
|
114 |
-
ref_eyeblink_coeff_path, _, _ = self.preprocess_model.generate(
|
115 |
-
ref_eyeblink, ref_eyeblink_frame_dir
|
116 |
-
)
|
117 |
-
else:
|
118 |
-
ref_eyeblink_coeff_path = None
|
119 |
-
|
120 |
-
if ref_pose is not None:
|
121 |
-
if ref_pose == ref_eyeblink:
|
122 |
-
ref_pose_coeff_path = ref_eyeblink_coeff_path
|
123 |
-
else:
|
124 |
-
ref_pose_videoname = os.path.splitext(os.path.split(ref_pose)[-1])[0]
|
125 |
-
ref_pose_frame_dir = os.path.join(results_dir, ref_pose_videoname)
|
126 |
-
os.makedirs(ref_pose_frame_dir, exist_ok=True)
|
127 |
-
print("3DMM Extraction for the reference video providing pose")
|
128 |
-
ref_pose_coeff_path, _, _ = self.preprocess_model.generate(
|
129 |
-
ref_pose, ref_pose_frame_dir
|
130 |
-
)
|
131 |
-
else:
|
132 |
-
ref_pose_coeff_path = None
|
133 |
-
|
134 |
-
# audio2ceoff
|
135 |
-
batch = get_data(
|
136 |
-
first_coeff_path,
|
137 |
-
args.audio_path,
|
138 |
-
device,
|
139 |
-
ref_eyeblink_coeff_path,
|
140 |
-
still=still,
|
141 |
-
)
|
142 |
-
coeff_path = self.audio_to_coeff.generate(
|
143 |
-
batch, results_dir, args.pose_style, ref_pose_coeff_path
|
144 |
-
)
|
145 |
-
# coeff2video
|
146 |
-
print("coeff2video")
|
147 |
-
data = get_facerender_data(
|
148 |
-
coeff_path,
|
149 |
-
crop_pic_path,
|
150 |
-
first_coeff_path,
|
151 |
-
args.audio_path,
|
152 |
-
args.batch_size,
|
153 |
-
args.input_yaw,
|
154 |
-
args.input_pitch,
|
155 |
-
args.input_roll,
|
156 |
-
expression_scale=args.expression_scale,
|
157 |
-
still_mode=still,
|
158 |
-
preprocess=preprocess,
|
159 |
-
)
|
160 |
-
animate_from_coeff.generate(
|
161 |
-
data, results_dir, args.pic_path, crop_info,
|
162 |
-
enhancer=enhancer, background_enhancer=args.background_enhancer,
|
163 |
-
preprocess=preprocess)
|
164 |
-
|
165 |
-
output = "/tmp/out.mp4"
|
166 |
-
mp4_path = os.path.join(results_dir, [f for f in os.listdir(results_dir) if "enhanced.mp4" in f][0])
|
167 |
-
shutil.copy(mp4_path, output)
|
168 |
-
|
169 |
-
return Path(output)
|
170 |
-
|
171 |
-
|
172 |
-
def load_default():
|
173 |
-
return Namespace(
|
174 |
-
pose_style=0,
|
175 |
-
batch_size=2,
|
176 |
-
expression_scale=1.0,
|
177 |
-
input_yaw=None,
|
178 |
-
input_pitch=None,
|
179 |
-
input_roll=None,
|
180 |
-
background_enhancer=None,
|
181 |
-
face3dvis=False,
|
182 |
-
net_recon="resnet50",
|
183 |
-
init_path=None,
|
184 |
-
use_last_fc=False,
|
185 |
-
bfm_folder="./src/config/",
|
186 |
-
bfm_model="BFM_model_front.mat",
|
187 |
-
focal=1015.0,
|
188 |
-
center=112.0,
|
189 |
-
camera_d=10.0,
|
190 |
-
z_near=5.0,
|
191 |
-
z_far=15.0,
|
192 |
-
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Amrrs/DragGan-Inversion/stylegan_human/pti/pti_models/e4e/stylegan2/op/fused_bias_act.cpp
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
#include <torch/extension.h>
|
2 |
-
|
3 |
-
|
4 |
-
torch::Tensor fused_bias_act_op(const torch::Tensor& input, const torch::Tensor& bias, const torch::Tensor& refer,
|
5 |
-
int act, int grad, float alpha, float scale);
|
6 |
-
|
7 |
-
#define CHECK_CUDA(x) TORCH_CHECK(x.type().is_cuda(), #x " must be a CUDA tensor")
|
8 |
-
#define CHECK_CONTIGUOUS(x) TORCH_CHECK(x.is_contiguous(), #x " must be contiguous")
|
9 |
-
#define CHECK_INPUT(x) CHECK_CUDA(x); CHECK_CONTIGUOUS(x)
|
10 |
-
|
11 |
-
torch::Tensor fused_bias_act(const torch::Tensor& input, const torch::Tensor& bias, const torch::Tensor& refer,
|
12 |
-
int act, int grad, float alpha, float scale) {
|
13 |
-
CHECK_CUDA(input);
|
14 |
-
CHECK_CUDA(bias);
|
15 |
-
|
16 |
-
return fused_bias_act_op(input, bias, refer, act, grad, alpha, scale);
|
17 |
-
}
|
18 |
-
|
19 |
-
PYBIND11_MODULE(TORCH_EXTENSION_NAME, m) {
|
20 |
-
m.def("fused_bias_act", &fused_bias_act, "fused bias act (CUDA)");
|
21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Androidonnxfork/CivitAi-to-Diffusers/diffusers/src/diffusers/pipelines/stable_diffusion_safe/safety_checker.py
DELETED
@@ -1,109 +0,0 @@
|
|
1 |
-
# Copyright 2023 The HuggingFace Team. All rights reserved.
|
2 |
-
#
|
3 |
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4 |
-
# you may not use this file except in compliance with the License.
|
5 |
-
# You may obtain a copy of the License at
|
6 |
-
#
|
7 |
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8 |
-
#
|
9 |
-
# Unless required by applicable law or agreed to in writing, software
|
10 |
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11 |
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12 |
-
# See the License for the specific language governing permissions and
|
13 |
-
# limitations under the License.
|
14 |
-
|
15 |
-
import torch
|
16 |
-
import torch.nn as nn
|
17 |
-
from transformers import CLIPConfig, CLIPVisionModel, PreTrainedModel
|
18 |
-
|
19 |
-
from ...utils import logging
|
20 |
-
|
21 |
-
|
22 |
-
logger = logging.get_logger(__name__)
|
23 |
-
|
24 |
-
|
25 |
-
def cosine_distance(image_embeds, text_embeds):
|
26 |
-
normalized_image_embeds = nn.functional.normalize(image_embeds)
|
27 |
-
normalized_text_embeds = nn.functional.normalize(text_embeds)
|
28 |
-
return torch.mm(normalized_image_embeds, normalized_text_embeds.t())
|
29 |
-
|
30 |
-
|
31 |
-
class SafeStableDiffusionSafetyChecker(PreTrainedModel):
|
32 |
-
config_class = CLIPConfig
|
33 |
-
|
34 |
-
_no_split_modules = ["CLIPEncoderLayer"]
|
35 |
-
|
36 |
-
def __init__(self, config: CLIPConfig):
|
37 |
-
super().__init__(config)
|
38 |
-
|
39 |
-
self.vision_model = CLIPVisionModel(config.vision_config)
|
40 |
-
self.visual_projection = nn.Linear(config.vision_config.hidden_size, config.projection_dim, bias=False)
|
41 |
-
|
42 |
-
self.concept_embeds = nn.Parameter(torch.ones(17, config.projection_dim), requires_grad=False)
|
43 |
-
self.special_care_embeds = nn.Parameter(torch.ones(3, config.projection_dim), requires_grad=False)
|
44 |
-
|
45 |
-
self.concept_embeds_weights = nn.Parameter(torch.ones(17), requires_grad=False)
|
46 |
-
self.special_care_embeds_weights = nn.Parameter(torch.ones(3), requires_grad=False)
|
47 |
-
|
48 |
-
@torch.no_grad()
|
49 |
-
def forward(self, clip_input, images):
|
50 |
-
pooled_output = self.vision_model(clip_input)[1] # pooled_output
|
51 |
-
image_embeds = self.visual_projection(pooled_output)
|
52 |
-
|
53 |
-
# we always cast to float32 as this does not cause significant overhead and is compatible with bfloat16
|
54 |
-
special_cos_dist = cosine_distance(image_embeds, self.special_care_embeds).cpu().float().numpy()
|
55 |
-
cos_dist = cosine_distance(image_embeds, self.concept_embeds).cpu().float().numpy()
|
56 |
-
|
57 |
-
result = []
|
58 |
-
batch_size = image_embeds.shape[0]
|
59 |
-
for i in range(batch_size):
|
60 |
-
result_img = {"special_scores": {}, "special_care": [], "concept_scores": {}, "bad_concepts": []}
|
61 |
-
|
62 |
-
# increase this value to create a stronger `nfsw` filter
|
63 |
-
# at the cost of increasing the possibility of filtering benign images
|
64 |
-
adjustment = 0.0
|
65 |
-
|
66 |
-
for concept_idx in range(len(special_cos_dist[0])):
|
67 |
-
concept_cos = special_cos_dist[i][concept_idx]
|
68 |
-
concept_threshold = self.special_care_embeds_weights[concept_idx].item()
|
69 |
-
result_img["special_scores"][concept_idx] = round(concept_cos - concept_threshold + adjustment, 3)
|
70 |
-
if result_img["special_scores"][concept_idx] > 0:
|
71 |
-
result_img["special_care"].append({concept_idx, result_img["special_scores"][concept_idx]})
|
72 |
-
adjustment = 0.01
|
73 |
-
|
74 |
-
for concept_idx in range(len(cos_dist[0])):
|
75 |
-
concept_cos = cos_dist[i][concept_idx]
|
76 |
-
concept_threshold = self.concept_embeds_weights[concept_idx].item()
|
77 |
-
result_img["concept_scores"][concept_idx] = round(concept_cos - concept_threshold + adjustment, 3)
|
78 |
-
if result_img["concept_scores"][concept_idx] > 0:
|
79 |
-
result_img["bad_concepts"].append(concept_idx)
|
80 |
-
|
81 |
-
result.append(result_img)
|
82 |
-
|
83 |
-
has_nsfw_concepts = [len(res["bad_concepts"]) > 0 for res in result]
|
84 |
-
|
85 |
-
return images, has_nsfw_concepts
|
86 |
-
|
87 |
-
@torch.no_grad()
|
88 |
-
def forward_onnx(self, clip_input: torch.FloatTensor, images: torch.FloatTensor):
|
89 |
-
pooled_output = self.vision_model(clip_input)[1] # pooled_output
|
90 |
-
image_embeds = self.visual_projection(pooled_output)
|
91 |
-
|
92 |
-
special_cos_dist = cosine_distance(image_embeds, self.special_care_embeds)
|
93 |
-
cos_dist = cosine_distance(image_embeds, self.concept_embeds)
|
94 |
-
|
95 |
-
# increase this value to create a stronger `nsfw` filter
|
96 |
-
# at the cost of increasing the possibility of filtering benign images
|
97 |
-
adjustment = 0.0
|
98 |
-
|
99 |
-
special_scores = special_cos_dist - self.special_care_embeds_weights + adjustment
|
100 |
-
# special_scores = special_scores.round(decimals=3)
|
101 |
-
special_care = torch.any(special_scores > 0, dim=1)
|
102 |
-
special_adjustment = special_care * 0.01
|
103 |
-
special_adjustment = special_adjustment.unsqueeze(1).expand(-1, cos_dist.shape[1])
|
104 |
-
|
105 |
-
concept_scores = (cos_dist - self.concept_embeds_weights) + special_adjustment
|
106 |
-
# concept_scores = concept_scores.round(decimals=3)
|
107 |
-
has_nsfw_concepts = torch.any(concept_scores > 0, dim=1)
|
108 |
-
|
109 |
-
return images, has_nsfw_concepts
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Andy1621/uniformer_image_detection/configs/faster_rcnn/faster_rcnn_r50_caffe_c4_1x_coco.py
DELETED
@@ -1,39 +0,0 @@
|
|
1 |
-
_base_ = [
|
2 |
-
'../_base_/models/faster_rcnn_r50_caffe_c4.py',
|
3 |
-
'../_base_/datasets/coco_detection.py',
|
4 |
-
'../_base_/schedules/schedule_1x.py', '../_base_/default_runtime.py'
|
5 |
-
]
|
6 |
-
# use caffe img_norm
|
7 |
-
img_norm_cfg = dict(
|
8 |
-
mean=[103.530, 116.280, 123.675], std=[1.0, 1.0, 1.0], to_rgb=False)
|
9 |
-
train_pipeline = [
|
10 |
-
dict(type='LoadImageFromFile'),
|
11 |
-
dict(type='LoadAnnotations', with_bbox=True),
|
12 |
-
dict(type='Resize', img_scale=(1333, 800), keep_ratio=True),
|
13 |
-
dict(type='RandomFlip', flip_ratio=0.5),
|
14 |
-
dict(type='Normalize', **img_norm_cfg),
|
15 |
-
dict(type='Pad', size_divisor=32),
|
16 |
-
dict(type='DefaultFormatBundle'),
|
17 |
-
dict(type='Collect', keys=['img', 'gt_bboxes', 'gt_labels']),
|
18 |
-
]
|
19 |
-
test_pipeline = [
|
20 |
-
dict(type='LoadImageFromFile'),
|
21 |
-
dict(
|
22 |
-
type='MultiScaleFlipAug',
|
23 |
-
img_scale=(1333, 800),
|
24 |
-
flip=False,
|
25 |
-
transforms=[
|
26 |
-
dict(type='Resize', keep_ratio=True),
|
27 |
-
dict(type='RandomFlip'),
|
28 |
-
dict(type='Normalize', **img_norm_cfg),
|
29 |
-
dict(type='Pad', size_divisor=32),
|
30 |
-
dict(type='ImageToTensor', keys=['img']),
|
31 |
-
dict(type='Collect', keys=['img']),
|
32 |
-
])
|
33 |
-
]
|
34 |
-
data = dict(
|
35 |
-
train=dict(pipeline=train_pipeline),
|
36 |
-
val=dict(pipeline=test_pipeline),
|
37 |
-
test=dict(pipeline=test_pipeline))
|
38 |
-
# optimizer
|
39 |
-
optimizer = dict(type='SGD', lr=0.01, momentum=0.9, weight_decay=0.0001)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Andy1621/uniformer_image_detection/mmdet/models/detectors/retinanet.py
DELETED
@@ -1,17 +0,0 @@
|
|
1 |
-
from ..builder import DETECTORS
|
2 |
-
from .single_stage import SingleStageDetector
|
3 |
-
|
4 |
-
|
5 |
-
@DETECTORS.register_module()
|
6 |
-
class RetinaNet(SingleStageDetector):
|
7 |
-
"""Implementation of `RetinaNet <https://arxiv.org/abs/1708.02002>`_"""
|
8 |
-
|
9 |
-
def __init__(self,
|
10 |
-
backbone,
|
11 |
-
neck,
|
12 |
-
bbox_head,
|
13 |
-
train_cfg=None,
|
14 |
-
test_cfg=None,
|
15 |
-
pretrained=None):
|
16 |
-
super(RetinaNet, self).__init__(backbone, neck, bbox_head, train_cfg,
|
17 |
-
test_cfg, pretrained)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Andy1621/uniformer_image_segmentation/configs/ocrnet/ocrnet_hr18s_512x1024_80k_cityscapes.py
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
_base_ = './ocrnet_hr18_512x1024_80k_cityscapes.py'
|
2 |
-
model = dict(
|
3 |
-
pretrained='open-mmlab://msra/hrnetv2_w18_small',
|
4 |
-
backbone=dict(
|
5 |
-
extra=dict(
|
6 |
-
stage1=dict(num_blocks=(2, )),
|
7 |
-
stage2=dict(num_blocks=(2, 2)),
|
8 |
-
stage3=dict(num_modules=3, num_blocks=(2, 2, 2)),
|
9 |
-
stage4=dict(num_modules=2, num_blocks=(2, 2, 2, 2)))))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Andy1621/uniformer_image_segmentation/configs/pspnet/pspnet_r50-d8_512x512_20k_voc12aug.py
DELETED
@@ -1,7 +0,0 @@
|
|
1 |
-
_base_ = [
|
2 |
-
'../_base_/models/pspnet_r50-d8.py',
|
3 |
-
'../_base_/datasets/pascal_voc12_aug.py', '../_base_/default_runtime.py',
|
4 |
-
'../_base_/schedules/schedule_20k.py'
|
5 |
-
]
|
6 |
-
model = dict(
|
7 |
-
decode_head=dict(num_classes=21), auxiliary_head=dict(num_classes=21))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AnishKumbhar/ChatBot/text-generation-webui-main/css/NotoSans/stylesheet.css
DELETED
@@ -1,166 +0,0 @@
|
|
1 |
-
/*
|
2 |
-
Copied from https://github.com/SillyTavern/SillyTavern/tree/6c8bd06308c69d51e2eb174541792a870a83d2d6/public/webfonts/NotoSans
|
3 |
-
*/
|
4 |
-
|
5 |
-
@font-face {
|
6 |
-
font-family: 'Noto Sans';
|
7 |
-
src: url('file/css/NotoSans/NotoSans-Black.woff2') format('woff2'),
|
8 |
-
url('file/css/NotoSans/NotoSans-Black.woff') format('woff');
|
9 |
-
font-weight: 900;
|
10 |
-
font-style: normal;
|
11 |
-
font-display: swap;
|
12 |
-
}
|
13 |
-
|
14 |
-
@font-face {
|
15 |
-
font-family: 'Noto Sans';
|
16 |
-
src: url('file/css/NotoSans/NotoSans-ExtraBoldItalic.woff2') format('woff2'),
|
17 |
-
url('file/css/NotoSans/NotoSans-ExtraBoldItalic.woff') format('woff');
|
18 |
-
font-weight: bold;
|
19 |
-
font-style: italic;
|
20 |
-
font-display: swap;
|
21 |
-
}
|
22 |
-
|
23 |
-
@font-face {
|
24 |
-
font-family: 'Noto Sans';
|
25 |
-
src: url('file/css/NotoSans/NotoSans-BlackItalic.woff2') format('woff2'),
|
26 |
-
url('file/css/NotoSans/NotoSans-BlackItalic.woff') format('woff');
|
27 |
-
font-weight: 900;
|
28 |
-
font-style: italic;
|
29 |
-
font-display: swap;
|
30 |
-
}
|
31 |
-
|
32 |
-
@font-face {
|
33 |
-
font-family: 'Noto Sans';
|
34 |
-
src: url('file/css/NotoSans/NotoSans-ExtraBold.woff2') format('woff2'),
|
35 |
-
url('file/css/NotoSans/NotoSans-ExtraBold.woff') format('woff');
|
36 |
-
font-weight: bold;
|
37 |
-
font-style: normal;
|
38 |
-
font-display: swap;
|
39 |
-
}
|
40 |
-
|
41 |
-
@font-face {
|
42 |
-
font-family: 'Noto Sans';
|
43 |
-
src: url('file/css/NotoSans/NotoSans-ThinItalic.woff2') format('woff2'),
|
44 |
-
url('file/css/NotoSans/NotoSans-ThinItalic.woff') format('woff');
|
45 |
-
font-weight: 100;
|
46 |
-
font-style: italic;
|
47 |
-
font-display: swap;
|
48 |
-
}
|
49 |
-
|
50 |
-
@font-face {
|
51 |
-
font-family: 'Noto Sans';
|
52 |
-
src: url('file/css/NotoSans/NotoSans-BoldItalic.woff2') format('woff2'),
|
53 |
-
url('file/css/NotoSans/NotoSans-BoldItalic.woff') format('woff');
|
54 |
-
font-weight: bold;
|
55 |
-
font-style: italic;
|
56 |
-
font-display: swap;
|
57 |
-
}
|
58 |
-
|
59 |
-
@font-face {
|
60 |
-
font-family: 'Noto Sans';
|
61 |
-
src: url('file/css/NotoSans/NotoSans-Bold.woff2') format('woff2'),
|
62 |
-
url('file/css/NotoSans/NotoSans-Bold.woff') format('woff');
|
63 |
-
font-weight: bold;
|
64 |
-
font-style: normal;
|
65 |
-
font-display: swap;
|
66 |
-
}
|
67 |
-
|
68 |
-
@font-face {
|
69 |
-
font-family: 'Noto Sans';
|
70 |
-
src: url('file/css/NotoSans/NotoSans-LightItalic.woff2') format('woff2'),
|
71 |
-
url('file/css/NotoSans/NotoSans-LightItalic.woff') format('woff');
|
72 |
-
font-weight: 300;
|
73 |
-
font-style: italic;
|
74 |
-
font-display: swap;
|
75 |
-
}
|
76 |
-
|
77 |
-
@font-face {
|
78 |
-
font-family: 'Noto Sans';
|
79 |
-
src: url('file/css/NotoSans/NotoSans-Italic.woff2') format('woff2'),
|
80 |
-
url('file/css/NotoSans/NotoSans-Italic.woff') format('woff');
|
81 |
-
font-weight: normal;
|
82 |
-
font-style: italic;
|
83 |
-
font-display: swap;
|
84 |
-
}
|
85 |
-
|
86 |
-
@font-face {
|
87 |
-
font-family: 'Noto Sans';
|
88 |
-
src: url('file/css/NotoSans/NotoSans-ExtraLightItalic.woff2') format('woff2'),
|
89 |
-
url('file/css/NotoSans/NotoSans-ExtraLightItalic.woff') format('woff');
|
90 |
-
font-weight: 200;
|
91 |
-
font-style: italic;
|
92 |
-
font-display: swap;
|
93 |
-
}
|
94 |
-
|
95 |
-
@font-face {
|
96 |
-
font-family: 'Noto Sans';
|
97 |
-
src: url('file/css/NotoSans/NotoSans-Light.woff2') format('woff2'),
|
98 |
-
url('file/css/NotoSans/NotoSans-Light.woff') format('woff');
|
99 |
-
font-weight: 300;
|
100 |
-
font-style: normal;
|
101 |
-
font-display: swap;
|
102 |
-
}
|
103 |
-
|
104 |
-
@font-face {
|
105 |
-
font-family: 'Noto Sans';
|
106 |
-
src: url('file/css/NotoSans/NotoSans-ExtraLight.woff2') format('woff2'),
|
107 |
-
url('file/css/NotoSans/NotoSans-ExtraLight.woff') format('woff');
|
108 |
-
font-weight: 200;
|
109 |
-
font-style: normal;
|
110 |
-
font-display: swap;
|
111 |
-
}
|
112 |
-
|
113 |
-
@font-face {
|
114 |
-
font-family: 'Noto Sans';
|
115 |
-
src: url('file/css/NotoSans/NotoSans-Medium.woff2') format('woff2'),
|
116 |
-
url('file/css/NotoSans/NotoSans-Medium.woff') format('woff');
|
117 |
-
font-weight: 500;
|
118 |
-
font-style: normal;
|
119 |
-
font-display: swap;
|
120 |
-
}
|
121 |
-
|
122 |
-
@font-face {
|
123 |
-
font-family: 'Noto Sans';
|
124 |
-
src: url('file/css/NotoSans/NotoSans-Regular.woff2') format('woff2'),
|
125 |
-
url('file/css/NotoSans/NotoSans-Regular.woff') format('woff');
|
126 |
-
font-weight: normal;
|
127 |
-
font-style: normal;
|
128 |
-
font-display: swap;
|
129 |
-
}
|
130 |
-
|
131 |
-
@font-face {
|
132 |
-
font-family: 'Noto Sans';
|
133 |
-
src: url('file/css/NotoSans/NotoSans-MediumItalic.woff2') format('woff2'),
|
134 |
-
url('file/css/NotoSans/NotoSans-MediumItalic.woff') format('woff');
|
135 |
-
font-weight: 500;
|
136 |
-
font-style: italic;
|
137 |
-
font-display: swap;
|
138 |
-
}
|
139 |
-
|
140 |
-
@font-face {
|
141 |
-
font-family: 'Noto Sans';
|
142 |
-
src: url('file/css/NotoSans/NotoSans-SemiBoldItalic.woff2') format('woff2'),
|
143 |
-
url('file/css/NotoSans/NotoSans-SemiBoldItalic.woff') format('woff');
|
144 |
-
font-weight: 600;
|
145 |
-
font-style: italic;
|
146 |
-
font-display: swap;
|
147 |
-
}
|
148 |
-
|
149 |
-
@font-face {
|
150 |
-
font-family: 'Noto Sans';
|
151 |
-
src: url('file/css/NotoSans/NotoSans-SemiBold.woff2') format('woff2'),
|
152 |
-
url('file/css/NotoSans/NotoSans-SemiBold.woff') format('woff');
|
153 |
-
font-weight: 600;
|
154 |
-
font-style: normal;
|
155 |
-
font-display: swap;
|
156 |
-
}
|
157 |
-
|
158 |
-
@font-face {
|
159 |
-
font-family: 'Noto Sans';
|
160 |
-
src: url('file/css/NotoSans/NotoSans-Thin.woff2') format('woff2'),
|
161 |
-
url('file/css/NotoSans/NotoSans-Thin.woff') format('woff');
|
162 |
-
font-weight: 100;
|
163 |
-
font-style: normal;
|
164 |
-
font-display: swap;
|
165 |
-
}
|
166 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/AnishKumbhar/ChatBot/text-generation-webui-main/js/main.js
DELETED
@@ -1,330 +0,0 @@
|
|
1 |
-
let main_parent = document.getElementById("chat-tab").parentNode;
|
2 |
-
let extensions = document.getElementById("extensions");
|
3 |
-
|
4 |
-
main_parent.childNodes[0].classList.add("header_bar");
|
5 |
-
main_parent.style = "padding: 0; margin: 0";
|
6 |
-
main_parent.parentNode.style = "gap: 0";
|
7 |
-
main_parent.parentNode.parentNode.style = "padding: 0";
|
8 |
-
|
9 |
-
document.querySelector(".header_bar").addEventListener("click", function(event) {
|
10 |
-
if (event.target.tagName === "BUTTON") {
|
11 |
-
const buttonText = event.target.textContent.trim();
|
12 |
-
|
13 |
-
let chat_visible = (buttonText == "Chat");
|
14 |
-
let default_visible = (buttonText == "Default");
|
15 |
-
let notebook_visible = (buttonText == "Notebook");
|
16 |
-
|
17 |
-
// Check if one of the generation tabs is visible
|
18 |
-
if (chat_visible || notebook_visible || default_visible) {
|
19 |
-
extensions.style.display = "flex";
|
20 |
-
if (chat_visible) {
|
21 |
-
extensions.style.maxWidth = "880px";
|
22 |
-
extensions.style.padding = "0px";
|
23 |
-
} else {
|
24 |
-
extensions.style.maxWidth = "none";
|
25 |
-
extensions.style.padding = "15px";
|
26 |
-
}
|
27 |
-
} else {
|
28 |
-
extensions.style.display = "none";
|
29 |
-
}
|
30 |
-
}
|
31 |
-
});
|
32 |
-
|
33 |
-
//------------------------------------------------
|
34 |
-
// Keyboard shortcuts
|
35 |
-
//------------------------------------------------
|
36 |
-
document.addEventListener("keydown", function(event) {
|
37 |
-
|
38 |
-
// Stop generation on Esc pressed
|
39 |
-
if (event.key === "Escape") {
|
40 |
-
// Find the element with id 'stop' and click it
|
41 |
-
var stopButton = document.getElementById("stop");
|
42 |
-
if (stopButton) {
|
43 |
-
stopButton.click();
|
44 |
-
}
|
45 |
-
}
|
46 |
-
|
47 |
-
// Show chat controls on Ctrl + S
|
48 |
-
else if (event.ctrlKey && event.key == "s") {
|
49 |
-
event.preventDefault();
|
50 |
-
|
51 |
-
var showControlsElement = document.getElementById("show-controls");
|
52 |
-
if (showControlsElement && showControlsElement.childNodes.length >= 4) {
|
53 |
-
showControlsElement.childNodes[3].click();
|
54 |
-
|
55 |
-
var arr = document.getElementById("chat-input").childNodes[2].childNodes;
|
56 |
-
arr[arr.length - 1].focus();
|
57 |
-
}
|
58 |
-
}
|
59 |
-
|
60 |
-
// Regenerate on Ctrl + Enter
|
61 |
-
else if (event.ctrlKey && event.key === "Enter") {
|
62 |
-
event.preventDefault();
|
63 |
-
document.getElementById("Regenerate").click();
|
64 |
-
}
|
65 |
-
|
66 |
-
// Continue on Alt + Enter
|
67 |
-
else if (event.altKey && event.key === "Enter") {
|
68 |
-
event.preventDefault();
|
69 |
-
document.getElementById("Continue").click();
|
70 |
-
}
|
71 |
-
|
72 |
-
// Remove last on Ctrl + Shift + Backspace
|
73 |
-
else if (event.ctrlKey && event.shiftKey && event.key === "Backspace") {
|
74 |
-
event.preventDefault();
|
75 |
-
document.getElementById("Remove-last").click();
|
76 |
-
}
|
77 |
-
|
78 |
-
// Copy last on Ctrl + Shift + K
|
79 |
-
else if (event.ctrlKey && event.shiftKey && event.key === "K") {
|
80 |
-
event.preventDefault();
|
81 |
-
document.getElementById("Copy-last").click();
|
82 |
-
}
|
83 |
-
|
84 |
-
// Replace last on Ctrl + Shift + L
|
85 |
-
else if (event.ctrlKey && event.shiftKey && event.key === "L") {
|
86 |
-
event.preventDefault();
|
87 |
-
document.getElementById("Replace-last").click();
|
88 |
-
}
|
89 |
-
|
90 |
-
// Impersonate on Ctrl + Shift + M
|
91 |
-
else if (event.ctrlKey && event.shiftKey && event.key === "M") {
|
92 |
-
event.preventDefault();
|
93 |
-
document.getElementById("Impersonate").click();
|
94 |
-
}
|
95 |
-
|
96 |
-
});
|
97 |
-
|
98 |
-
//------------------------------------------------
|
99 |
-
// Position the chat typing dots
|
100 |
-
//------------------------------------------------
|
101 |
-
typing = document.getElementById("typing-container");
|
102 |
-
typingParent = typing.parentNode;
|
103 |
-
typingSibling = typing.previousElementSibling;
|
104 |
-
typingSibling.insertBefore(typing, typingSibling.childNodes[2]);
|
105 |
-
|
106 |
-
//------------------------------------------------
|
107 |
-
// Chat scrolling
|
108 |
-
//------------------------------------------------
|
109 |
-
const targetElement = document.getElementById("chat").parentNode.parentNode.parentNode;
|
110 |
-
targetElement.classList.add("pretty_scrollbar");
|
111 |
-
targetElement.classList.add("chat-parent");
|
112 |
-
let isScrolled = false;
|
113 |
-
|
114 |
-
targetElement.addEventListener("scroll", function() {
|
115 |
-
let diff = targetElement.scrollHeight - targetElement.clientHeight;
|
116 |
-
if(Math.abs(targetElement.scrollTop - diff) <= 10 || diff == 0) {
|
117 |
-
isScrolled = false;
|
118 |
-
} else {
|
119 |
-
isScrolled = true;
|
120 |
-
}
|
121 |
-
});
|
122 |
-
|
123 |
-
// Create a MutationObserver instance
|
124 |
-
const observer = new MutationObserver(function(mutations) {
|
125 |
-
mutations.forEach(function(mutation) {
|
126 |
-
if(!isScrolled) {
|
127 |
-
targetElement.scrollTop = targetElement.scrollHeight;
|
128 |
-
}
|
129 |
-
|
130 |
-
const firstChild = targetElement.children[0];
|
131 |
-
if (firstChild.classList.contains("generating")) {
|
132 |
-
typing.parentNode.classList.add("visible-dots");
|
133 |
-
document.getElementById("stop").style.display = "flex";
|
134 |
-
document.getElementById("Generate").style.display = "none";
|
135 |
-
} else {
|
136 |
-
typing.parentNode.classList.remove("visible-dots");
|
137 |
-
document.getElementById("stop").style.display = "none";
|
138 |
-
document.getElementById("Generate").style.display = "flex";
|
139 |
-
}
|
140 |
-
|
141 |
-
});
|
142 |
-
});
|
143 |
-
|
144 |
-
// Configure the observer to watch for changes in the subtree and attributes
|
145 |
-
const config = {
|
146 |
-
childList: true,
|
147 |
-
subtree: true,
|
148 |
-
characterData: true,
|
149 |
-
attributeOldValue: true,
|
150 |
-
characterDataOldValue: true
|
151 |
-
};
|
152 |
-
|
153 |
-
// Start observing the target element
|
154 |
-
observer.observe(targetElement, config);
|
155 |
-
|
156 |
-
//------------------------------------------------
|
157 |
-
// Notebook box scrolling
|
158 |
-
//------------------------------------------------
|
159 |
-
const notebookElement = document.querySelector("#textbox-notebook textarea");
|
160 |
-
let notebookScrolled = false;
|
161 |
-
|
162 |
-
notebookElement.addEventListener("scroll", function() {
|
163 |
-
let diff = notebookElement.scrollHeight - notebookElement.clientHeight;
|
164 |
-
if(Math.abs(notebookElement.scrollTop - diff) <= 10 || diff == 0) {
|
165 |
-
notebookScrolled = false;
|
166 |
-
} else {
|
167 |
-
notebookScrolled = true;
|
168 |
-
}
|
169 |
-
});
|
170 |
-
|
171 |
-
const notebookObserver = new MutationObserver(function(mutations) {
|
172 |
-
mutations.forEach(function(mutation) {
|
173 |
-
if(!notebookScrolled) {
|
174 |
-
notebookElement.scrollTop = notebookElement.scrollHeight;
|
175 |
-
}
|
176 |
-
});
|
177 |
-
});
|
178 |
-
|
179 |
-
notebookObserver.observe(notebookElement.parentNode.parentNode.parentNode, config);
|
180 |
-
|
181 |
-
//------------------------------------------------
|
182 |
-
// Default box scrolling
|
183 |
-
//------------------------------------------------
|
184 |
-
const defaultElement = document.querySelector("#textbox-default textarea");
|
185 |
-
let defaultScrolled = false;
|
186 |
-
|
187 |
-
defaultElement.addEventListener("scroll", function() {
|
188 |
-
let diff = defaultElement.scrollHeight - defaultElement.clientHeight;
|
189 |
-
if(Math.abs(defaultElement.scrollTop - diff) <= 10 || diff == 0) {
|
190 |
-
defaultScrolled = false;
|
191 |
-
} else {
|
192 |
-
defaultScrolled = true;
|
193 |
-
}
|
194 |
-
});
|
195 |
-
|
196 |
-
const defaultObserver = new MutationObserver(function(mutations) {
|
197 |
-
mutations.forEach(function(mutation) {
|
198 |
-
if(!defaultScrolled) {
|
199 |
-
defaultElement.scrollTop = defaultElement.scrollHeight;
|
200 |
-
}
|
201 |
-
});
|
202 |
-
});
|
203 |
-
|
204 |
-
defaultObserver.observe(defaultElement.parentNode.parentNode.parentNode, config);
|
205 |
-
|
206 |
-
//------------------------------------------------
|
207 |
-
// Add some scrollbars
|
208 |
-
//------------------------------------------------
|
209 |
-
const textareaElements = document.querySelectorAll(".add_scrollbar textarea");
|
210 |
-
for(i = 0; i < textareaElements.length; i++) {
|
211 |
-
textareaElements[i].classList.remove("scroll-hide");
|
212 |
-
textareaElements[i].classList.add("pretty_scrollbar");
|
213 |
-
textareaElements[i].style.resize = "none";
|
214 |
-
}
|
215 |
-
|
216 |
-
//------------------------------------------------
|
217 |
-
// Remove some backgrounds
|
218 |
-
//------------------------------------------------
|
219 |
-
const noBackgroundelements = document.querySelectorAll(".no-background");
|
220 |
-
for(i = 0; i < noBackgroundelements.length; i++) {
|
221 |
-
noBackgroundelements[i].parentNode.style.border = "none";
|
222 |
-
noBackgroundelements[i].parentNode.parentNode.parentNode.style.alignItems = "center";
|
223 |
-
}
|
224 |
-
|
225 |
-
//------------------------------------------------
|
226 |
-
// Create the hover menu in the chat tab
|
227 |
-
// The show/hide events were adapted from:
|
228 |
-
// https://github.com/SillyTavern/SillyTavern/blob/6c8bd06308c69d51e2eb174541792a870a83d2d6/public/script.js
|
229 |
-
//------------------------------------------------
|
230 |
-
var buttonsInChat = document.querySelectorAll("#chat-tab:not(.old-ui) #chat-buttons button");
|
231 |
-
var button = document.getElementById("hover-element-button");
|
232 |
-
var menu = document.getElementById("hover-menu");
|
233 |
-
|
234 |
-
function showMenu() {
|
235 |
-
menu.style.display = "flex"; // Show the menu
|
236 |
-
}
|
237 |
-
|
238 |
-
function hideMenu() {
|
239 |
-
menu.style.display = "none"; // Hide the menu
|
240 |
-
document.querySelector("#chat-input textarea").focus();
|
241 |
-
}
|
242 |
-
|
243 |
-
if (buttonsInChat.length > 0) {
|
244 |
-
for (let i = buttonsInChat.length - 1; i >= 0; i--) {
|
245 |
-
const thisButton = buttonsInChat[i];
|
246 |
-
menu.appendChild(thisButton);
|
247 |
-
|
248 |
-
thisButton.addEventListener("click", () => {
|
249 |
-
hideMenu();
|
250 |
-
});
|
251 |
-
|
252 |
-
const buttonText = thisButton.textContent;
|
253 |
-
const matches = buttonText.match(/(\(.*?\))/);
|
254 |
-
|
255 |
-
if (matches && matches.length > 1) {
|
256 |
-
// Apply the transparent-substring class to the matched substring
|
257 |
-
const substring = matches[1];
|
258 |
-
const newText = buttonText.replace(substring, ` <span class="transparent-substring">${substring.slice(1, -1)}</span>`);
|
259 |
-
thisButton.innerHTML = newText;
|
260 |
-
}
|
261 |
-
}
|
262 |
-
} else {
|
263 |
-
buttonsInChat = document.querySelectorAll("#chat-tab.old-ui #chat-buttons button");
|
264 |
-
for (let i = 0; i < buttonsInChat.length; i++) {
|
265 |
-
buttonsInChat[i].textContent = buttonsInChat[i].textContent.replace(/ \(.*?\)/, "");
|
266 |
-
}
|
267 |
-
document.getElementById("gr-hover-container").style.display = "none";
|
268 |
-
}
|
269 |
-
|
270 |
-
function isMouseOverButtonOrMenu() {
|
271 |
-
return menu.matches(":hover") || button.matches(":hover");
|
272 |
-
}
|
273 |
-
|
274 |
-
button.addEventListener("mouseenter", function () {
|
275 |
-
showMenu();
|
276 |
-
});
|
277 |
-
|
278 |
-
button.addEventListener("click", function () {
|
279 |
-
showMenu();
|
280 |
-
});
|
281 |
-
|
282 |
-
// Add event listener for mouseleave on the button
|
283 |
-
button.addEventListener("mouseleave", function () {
|
284 |
-
// Delay to prevent menu hiding when the mouse leaves the button into the menu
|
285 |
-
setTimeout(function () {
|
286 |
-
if (!isMouseOverButtonOrMenu()) {
|
287 |
-
hideMenu();
|
288 |
-
}
|
289 |
-
}, 100);
|
290 |
-
});
|
291 |
-
|
292 |
-
// Add event listener for mouseleave on the menu
|
293 |
-
menu.addEventListener("mouseleave", function () {
|
294 |
-
// Delay to prevent menu hide when the mouse leaves the menu into the button
|
295 |
-
setTimeout(function () {
|
296 |
-
if (!isMouseOverButtonOrMenu()) {
|
297 |
-
hideMenu();
|
298 |
-
}
|
299 |
-
}, 100);
|
300 |
-
});
|
301 |
-
|
302 |
-
// Add event listener for click anywhere in the document
|
303 |
-
document.addEventListener("click", function (event) {
|
304 |
-
// Check if the click is outside the button/menu and the menu is visible
|
305 |
-
if (!isMouseOverButtonOrMenu() && menu.style.display === "flex") {
|
306 |
-
hideMenu();
|
307 |
-
}
|
308 |
-
});
|
309 |
-
|
310 |
-
//------------------------------------------------
|
311 |
-
// Relocate the "Show controls" checkbox
|
312 |
-
//------------------------------------------------
|
313 |
-
var elementToMove = document.getElementById("show-controls");
|
314 |
-
var parent = elementToMove.parentNode;
|
315 |
-
for (var i = 0; i < 2; i++) {
|
316 |
-
parent = parent.parentNode;
|
317 |
-
}
|
318 |
-
|
319 |
-
parent.insertBefore(elementToMove, parent.firstChild);
|
320 |
-
|
321 |
-
//------------------------------------------------
|
322 |
-
// Make the chat input grow upwards instead of downwards
|
323 |
-
//------------------------------------------------
|
324 |
-
document.getElementById("show-controls").parentNode.style.position = "absolute";
|
325 |
-
document.getElementById("show-controls").parentNode.style.bottom = "0px";
|
326 |
-
|
327 |
-
//------------------------------------------------
|
328 |
-
// Focus on the chat input
|
329 |
-
//------------------------------------------------
|
330 |
-
document.querySelector("#chat-input textarea").focus();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Anonymous-123/ImageNet-Editing/editing_diffusion/guided_diffusion/README.md
DELETED
@@ -1,176 +0,0 @@
|
|
1 |
-
# guided-diffusion
|
2 |
-
|
3 |
-
This is the codebase for [Diffusion Models Beat GANS on Image Synthesis](http://arxiv.org/abs/2105.05233).
|
4 |
-
|
5 |
-
This repository is based on [openai/improved-diffusion](https://github.com/openai/improved-diffusion), with modifications for classifier conditioning and architecture improvements.
|
6 |
-
|
7 |
-
# Download pre-trained models
|
8 |
-
|
9 |
-
We have released checkpoints for the main models in the paper. Before using these models, please review the corresponding [model card](model-card.md) to understand the intended use and limitations of these models.
|
10 |
-
|
11 |
-
Here are the download links for each model checkpoint:
|
12 |
-
|
13 |
-
* 64x64 classifier: [64x64_classifier.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/64x64_classifier.pt)
|
14 |
-
* 64x64 diffusion: [64x64_diffusion.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/64x64_diffusion.pt)
|
15 |
-
* 128x128 classifier: [128x128_classifier.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/128x128_classifier.pt)
|
16 |
-
* 128x128 diffusion: [128x128_diffusion.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/128x128_diffusion.pt)
|
17 |
-
* 256x256 classifier: [256x256_classifier.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/256x256_classifier.pt)
|
18 |
-
* 256x256 diffusion: [256x256_diffusion.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/256x256_diffusion.pt)
|
19 |
-
* 256x256 diffusion (not class conditional): [256x256_diffusion_uncond.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/256x256_diffusion_uncond.pt)
|
20 |
-
* 512x512 classifier: [512x512_classifier.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/512x512_classifier.pt)
|
21 |
-
* 512x512 diffusion: [512x512_diffusion.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/512x512_diffusion.pt)
|
22 |
-
* 64x64 -> 256x256 upsampler: [64_256_upsampler.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/64_256_upsampler.pt)
|
23 |
-
* 128x128 -> 512x512 upsampler: [128_512_upsampler.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/128_512_upsampler.pt)
|
24 |
-
* LSUN bedroom: [lsun_bedroom.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/lsun_bedroom.pt)
|
25 |
-
* LSUN cat: [lsun_cat.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/lsun_cat.pt)
|
26 |
-
* LSUN horse: [lsun_horse.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/lsun_horse.pt)
|
27 |
-
* LSUN horse (no dropout): [lsun_horse_nodropout.pt](https://openaipublic.blob.core.windows.net/diffusion/jul-2021/lsun_horse_nodropout.pt)
|
28 |
-
|
29 |
-
# Sampling from pre-trained models
|
30 |
-
|
31 |
-
To sample from these models, you can use the `classifier_sample.py`, `image_sample.py`, and `super_res_sample.py` scripts.
|
32 |
-
Here, we provide flags for sampling from all of these models.
|
33 |
-
We assume that you have downloaded the relevant model checkpoints into a folder called `models/`.
|
34 |
-
|
35 |
-
For these examples, we will generate 100 samples with batch size 4. Feel free to change these values.
|
36 |
-
|
37 |
-
```
|
38 |
-
SAMPLE_FLAGS="--batch_size 4 --num_samples 100 --timestep_respacing 250"
|
39 |
-
```
|
40 |
-
|
41 |
-
## Classifier guidance
|
42 |
-
|
43 |
-
Note for these sampling runs that you can set `--classifier_scale 0` to sample from the base diffusion model.
|
44 |
-
You may also use the `image_sample.py` script instead of `classifier_sample.py` in that case.
|
45 |
-
|
46 |
-
* 64x64 model:
|
47 |
-
|
48 |
-
```
|
49 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --diffusion_steps 1000 --dropout 0.1 --image_size 64 --learn_sigma True --noise_schedule cosine --num_channels 192 --num_head_channels 64 --num_res_blocks 3 --resblock_updown True --use_new_attention_order True --use_fp16 True --use_scale_shift_norm True"
|
50 |
-
python classifier_sample.py $MODEL_FLAGS --classifier_scale 1.0 --classifier_path models/64x64_classifier.pt --model_path models/64x64_diffusion.pt $SAMPLE_FLAGS
|
51 |
-
```
|
52 |
-
|
53 |
-
* 128x128 model:
|
54 |
-
|
55 |
-
```
|
56 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --diffusion_steps 1000 --image_size 128 --learn_sigma True --noise_schedule linear --num_channels 256 --num_heads 4 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
57 |
-
python classifier_sample.py $MODEL_FLAGS --classifier_scale 0.5 --classifier_path models/128x128_classifier.pt --model_path models/128x128_diffusion.pt $SAMPLE_FLAGS
|
58 |
-
```
|
59 |
-
|
60 |
-
* 256x256 model:
|
61 |
-
|
62 |
-
```
|
63 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --diffusion_steps 1000 --image_size 256 --learn_sigma True --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
64 |
-
python classifier_sample.py $MODEL_FLAGS --classifier_scale 1.0 --classifier_path models/256x256_classifier.pt --model_path models/256x256_diffusion.pt $SAMPLE_FLAGS
|
65 |
-
```
|
66 |
-
|
67 |
-
* 256x256 model (unconditional):
|
68 |
-
|
69 |
-
```
|
70 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond False --diffusion_steps 1000 --image_size 256 --learn_sigma True --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
71 |
-
python classifier_sample.py $MODEL_FLAGS --classifier_scale 10.0 --classifier_path models/256x256_classifier.pt --model_path models/256x256_diffusion.pt $SAMPLE_FLAGS
|
72 |
-
```
|
73 |
-
|
74 |
-
* 512x512 model:
|
75 |
-
|
76 |
-
```
|
77 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --diffusion_steps 1000 --image_size 512 --learn_sigma True --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 False --use_scale_shift_norm True"
|
78 |
-
python classifier_sample.py $MODEL_FLAGS --classifier_scale 4.0 --classifier_path models/512x512_classifier.pt --model_path models/512x512_diffusion.pt $SAMPLE_FLAGS
|
79 |
-
```
|
80 |
-
|
81 |
-
## Upsampling
|
82 |
-
|
83 |
-
For these runs, we assume you have some base samples in a file `64_samples.npz` or `128_samples.npz` for the two respective models.
|
84 |
-
|
85 |
-
* 64 -> 256:
|
86 |
-
|
87 |
-
```
|
88 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --diffusion_steps 1000 --large_size 256 --small_size 64 --learn_sigma True --noise_schedule linear --num_channels 192 --num_heads 4 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
89 |
-
python super_res_sample.py $MODEL_FLAGS --model_path models/64_256_upsampler.pt --base_samples 64_samples.npz $SAMPLE_FLAGS
|
90 |
-
```
|
91 |
-
|
92 |
-
* 128 -> 512:
|
93 |
-
|
94 |
-
```
|
95 |
-
MODEL_FLAGS="--attention_resolutions 32,16 --class_cond True --diffusion_steps 1000 --large_size 512 --small_size 128 --learn_sigma True --noise_schedule linear --num_channels 192 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
96 |
-
python super_res_sample.py $MODEL_FLAGS --model_path models/128_512_upsampler.pt $SAMPLE_FLAGS --base_samples 128_samples.npz
|
97 |
-
```
|
98 |
-
|
99 |
-
## LSUN models
|
100 |
-
|
101 |
-
These models are class-unconditional and correspond to a single LSUN class. Here, we show how to sample from `lsun_bedroom.pt`, but the other two LSUN checkpoints should work as well:
|
102 |
-
|
103 |
-
```
|
104 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond False --diffusion_steps 1000 --dropout 0.1 --image_size 256 --learn_sigma True --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
105 |
-
python image_sample.py $MODEL_FLAGS --model_path models/lsun_bedroom.pt $SAMPLE_FLAGS
|
106 |
-
```
|
107 |
-
|
108 |
-
You can sample from `lsun_horse_nodropout.pt` by changing the dropout flag:
|
109 |
-
|
110 |
-
```
|
111 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond False --diffusion_steps 1000 --dropout 0.0 --image_size 256 --learn_sigma True --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
112 |
-
python image_sample.py $MODEL_FLAGS --model_path models/lsun_horse_nodropout.pt $SAMPLE_FLAGS
|
113 |
-
```
|
114 |
-
|
115 |
-
Note that for these models, the best samples result from using 1000 timesteps:
|
116 |
-
|
117 |
-
```
|
118 |
-
SAMPLE_FLAGS="--batch_size 4 --num_samples 100 --timestep_respacing 1000"
|
119 |
-
```
|
120 |
-
|
121 |
-
# Results
|
122 |
-
|
123 |
-
This table summarizes our ImageNet results for pure guided diffusion models:
|
124 |
-
|
125 |
-
| Dataset | FID | Precision | Recall |
|
126 |
-
|------------------|------|-----------|--------|
|
127 |
-
| ImageNet 64x64 | 2.07 | 0.74 | 0.63 |
|
128 |
-
| ImageNet 128x128 | 2.97 | 0.78 | 0.59 |
|
129 |
-
| ImageNet 256x256 | 4.59 | 0.82 | 0.52 |
|
130 |
-
| ImageNet 512x512 | 7.72 | 0.87 | 0.42 |
|
131 |
-
|
132 |
-
This table shows the best results for high resolutions when using upsampling and guidance together:
|
133 |
-
|
134 |
-
| Dataset | FID | Precision | Recall |
|
135 |
-
|------------------|------|-----------|--------|
|
136 |
-
| ImageNet 256x256 | 3.94 | 0.83 | 0.53 |
|
137 |
-
| ImageNet 512x512 | 3.85 | 0.84 | 0.53 |
|
138 |
-
|
139 |
-
Finally, here are the unguided results on individual LSUN classes:
|
140 |
-
|
141 |
-
| Dataset | FID | Precision | Recall |
|
142 |
-
|--------------|------|-----------|--------|
|
143 |
-
| LSUN Bedroom | 1.90 | 0.66 | 0.51 |
|
144 |
-
| LSUN Cat | 5.57 | 0.63 | 0.52 |
|
145 |
-
| LSUN Horse | 2.57 | 0.71 | 0.55 |
|
146 |
-
|
147 |
-
# Training models
|
148 |
-
|
149 |
-
Training diffusion models is described in the [parent repository](https://github.com/openai/improved-diffusion). Training a classifier is similar. We assume you have put training hyperparameters into a `TRAIN_FLAGS` variable, and classifier hyperparameters into a `CLASSIFIER_FLAGS` variable. Then you can run:
|
150 |
-
|
151 |
-
```
|
152 |
-
mpiexec -n N python scripts/classifier_train.py --data_dir path/to/imagenet $TRAIN_FLAGS $CLASSIFIER_FLAGS
|
153 |
-
```
|
154 |
-
|
155 |
-
Make sure to divide the batch size in `TRAIN_FLAGS` by the number of MPI processes you are using.
|
156 |
-
|
157 |
-
Here are flags for training the 128x128 classifier. You can modify these for training classifiers at other resolutions:
|
158 |
-
|
159 |
-
```sh
|
160 |
-
TRAIN_FLAGS="--iterations 300000 --anneal_lr True --batch_size 256 --lr 3e-4 --save_interval 10000 --weight_decay 0.05"
|
161 |
-
CLASSIFIER_FLAGS="--image_size 128 --classifier_attention_resolutions 32,16,8 --classifier_depth 2 --classifier_width 128 --classifier_pool attention --classifier_resblock_updown True --classifier_use_scale_shift_norm True"
|
162 |
-
```
|
163 |
-
|
164 |
-
For sampling from a 128x128 classifier-guided model, 25 step DDIM:
|
165 |
-
|
166 |
-
```sh
|
167 |
-
MODEL_FLAGS="--attention_resolutions 32,16,8 --class_cond True --image_size 128 --learn_sigma True --num_channels 256 --num_heads 4 --num_res_blocks 2 --resblock_updown True --use_fp16 True --use_scale_shift_norm True"
|
168 |
-
CLASSIFIER_FLAGS="--image_size 128 --classifier_attention_resolutions 32,16,8 --classifier_depth 2 --classifier_width 128 --classifier_pool attention --classifier_resblock_updown True --classifier_use_scale_shift_norm True --classifier_scale 1.0 --classifier_use_fp16 True"
|
169 |
-
SAMPLE_FLAGS="--batch_size 4 --num_samples 50000 --timestep_respacing ddim25 --use_ddim True"
|
170 |
-
mpiexec -n N python scripts/classifier_sample.py \
|
171 |
-
--model_path /path/to/model.pt \
|
172 |
-
--classifier_path path/to/classifier.pt \
|
173 |
-
$MODEL_FLAGS $CLASSIFIER_FLAGS $SAMPLE_FLAGS
|
174 |
-
```
|
175 |
-
|
176 |
-
To sample for 250 timesteps without DDIM, replace `--timestep_respacing ddim25` to `--timestep_respacing 250`, and replace `--use_ddim True` with `--use_ddim False`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Anonymous-sub/Rerender/ControlNet/annotator/uniformer/mmcv/ops/saconv.py
DELETED
@@ -1,145 +0,0 @@
|
|
1 |
-
# Copyright (c) OpenMMLab. All rights reserved.
|
2 |
-
import torch
|
3 |
-
import torch.nn as nn
|
4 |
-
import torch.nn.functional as F
|
5 |
-
|
6 |
-
from annotator.uniformer.mmcv.cnn import CONV_LAYERS, ConvAWS2d, constant_init
|
7 |
-
from annotator.uniformer.mmcv.ops.deform_conv import deform_conv2d
|
8 |
-
from annotator.uniformer.mmcv.utils import TORCH_VERSION, digit_version
|
9 |
-
|
10 |
-
|
11 |
-
@CONV_LAYERS.register_module(name='SAC')
|
12 |
-
class SAConv2d(ConvAWS2d):
|
13 |
-
"""SAC (Switchable Atrous Convolution)
|
14 |
-
|
15 |
-
This is an implementation of SAC in DetectoRS
|
16 |
-
(https://arxiv.org/pdf/2006.02334.pdf).
|
17 |
-
|
18 |
-
Args:
|
19 |
-
in_channels (int): Number of channels in the input image
|
20 |
-
out_channels (int): Number of channels produced by the convolution
|
21 |
-
kernel_size (int or tuple): Size of the convolving kernel
|
22 |
-
stride (int or tuple, optional): Stride of the convolution. Default: 1
|
23 |
-
padding (int or tuple, optional): Zero-padding added to both sides of
|
24 |
-
the input. Default: 0
|
25 |
-
padding_mode (string, optional): ``'zeros'``, ``'reflect'``,
|
26 |
-
``'replicate'`` or ``'circular'``. Default: ``'zeros'``
|
27 |
-
dilation (int or tuple, optional): Spacing between kernel elements.
|
28 |
-
Default: 1
|
29 |
-
groups (int, optional): Number of blocked connections from input
|
30 |
-
channels to output channels. Default: 1
|
31 |
-
bias (bool, optional): If ``True``, adds a learnable bias to the
|
32 |
-
output. Default: ``True``
|
33 |
-
use_deform: If ``True``, replace convolution with deformable
|
34 |
-
convolution. Default: ``False``.
|
35 |
-
"""
|
36 |
-
|
37 |
-
def __init__(self,
|
38 |
-
in_channels,
|
39 |
-
out_channels,
|
40 |
-
kernel_size,
|
41 |
-
stride=1,
|
42 |
-
padding=0,
|
43 |
-
dilation=1,
|
44 |
-
groups=1,
|
45 |
-
bias=True,
|
46 |
-
use_deform=False):
|
47 |
-
super().__init__(
|
48 |
-
in_channels,
|
49 |
-
out_channels,
|
50 |
-
kernel_size,
|
51 |
-
stride=stride,
|
52 |
-
padding=padding,
|
53 |
-
dilation=dilation,
|
54 |
-
groups=groups,
|
55 |
-
bias=bias)
|
56 |
-
self.use_deform = use_deform
|
57 |
-
self.switch = nn.Conv2d(
|
58 |
-
self.in_channels, 1, kernel_size=1, stride=stride, bias=True)
|
59 |
-
self.weight_diff = nn.Parameter(torch.Tensor(self.weight.size()))
|
60 |
-
self.pre_context = nn.Conv2d(
|
61 |
-
self.in_channels, self.in_channels, kernel_size=1, bias=True)
|
62 |
-
self.post_context = nn.Conv2d(
|
63 |
-
self.out_channels, self.out_channels, kernel_size=1, bias=True)
|
64 |
-
if self.use_deform:
|
65 |
-
self.offset_s = nn.Conv2d(
|
66 |
-
self.in_channels,
|
67 |
-
18,
|
68 |
-
kernel_size=3,
|
69 |
-
padding=1,
|
70 |
-
stride=stride,
|
71 |
-
bias=True)
|
72 |
-
self.offset_l = nn.Conv2d(
|
73 |
-
self.in_channels,
|
74 |
-
18,
|
75 |
-
kernel_size=3,
|
76 |
-
padding=1,
|
77 |
-
stride=stride,
|
78 |
-
bias=True)
|
79 |
-
self.init_weights()
|
80 |
-
|
81 |
-
def init_weights(self):
|
82 |
-
constant_init(self.switch, 0, bias=1)
|
83 |
-
self.weight_diff.data.zero_()
|
84 |
-
constant_init(self.pre_context, 0)
|
85 |
-
constant_init(self.post_context, 0)
|
86 |
-
if self.use_deform:
|
87 |
-
constant_init(self.offset_s, 0)
|
88 |
-
constant_init(self.offset_l, 0)
|
89 |
-
|
90 |
-
def forward(self, x):
|
91 |
-
# pre-context
|
92 |
-
avg_x = F.adaptive_avg_pool2d(x, output_size=1)
|
93 |
-
avg_x = self.pre_context(avg_x)
|
94 |
-
avg_x = avg_x.expand_as(x)
|
95 |
-
x = x + avg_x
|
96 |
-
# switch
|
97 |
-
avg_x = F.pad(x, pad=(2, 2, 2, 2), mode='reflect')
|
98 |
-
avg_x = F.avg_pool2d(avg_x, kernel_size=5, stride=1, padding=0)
|
99 |
-
switch = self.switch(avg_x)
|
100 |
-
# sac
|
101 |
-
weight = self._get_weight(self.weight)
|
102 |
-
zero_bias = torch.zeros(
|
103 |
-
self.out_channels, device=weight.device, dtype=weight.dtype)
|
104 |
-
|
105 |
-
if self.use_deform:
|
106 |
-
offset = self.offset_s(avg_x)
|
107 |
-
out_s = deform_conv2d(x, offset, weight, self.stride, self.padding,
|
108 |
-
self.dilation, self.groups, 1)
|
109 |
-
else:
|
110 |
-
if (TORCH_VERSION == 'parrots'
|
111 |
-
or digit_version(TORCH_VERSION) < digit_version('1.5.0')):
|
112 |
-
out_s = super().conv2d_forward(x, weight)
|
113 |
-
elif digit_version(TORCH_VERSION) >= digit_version('1.8.0'):
|
114 |
-
# bias is a required argument of _conv_forward in torch 1.8.0
|
115 |
-
out_s = super()._conv_forward(x, weight, zero_bias)
|
116 |
-
else:
|
117 |
-
out_s = super()._conv_forward(x, weight)
|
118 |
-
ori_p = self.padding
|
119 |
-
ori_d = self.dilation
|
120 |
-
self.padding = tuple(3 * p for p in self.padding)
|
121 |
-
self.dilation = tuple(3 * d for d in self.dilation)
|
122 |
-
weight = weight + self.weight_diff
|
123 |
-
if self.use_deform:
|
124 |
-
offset = self.offset_l(avg_x)
|
125 |
-
out_l = deform_conv2d(x, offset, weight, self.stride, self.padding,
|
126 |
-
self.dilation, self.groups, 1)
|
127 |
-
else:
|
128 |
-
if (TORCH_VERSION == 'parrots'
|
129 |
-
or digit_version(TORCH_VERSION) < digit_version('1.5.0')):
|
130 |
-
out_l = super().conv2d_forward(x, weight)
|
131 |
-
elif digit_version(TORCH_VERSION) >= digit_version('1.8.0'):
|
132 |
-
# bias is a required argument of _conv_forward in torch 1.8.0
|
133 |
-
out_l = super()._conv_forward(x, weight, zero_bias)
|
134 |
-
else:
|
135 |
-
out_l = super()._conv_forward(x, weight)
|
136 |
-
|
137 |
-
out = switch * out_s + (1 - switch) * out_l
|
138 |
-
self.padding = ori_p
|
139 |
-
self.dilation = ori_d
|
140 |
-
# post-context
|
141 |
-
avg_x = F.adaptive_avg_pool2d(out, output_size=1)
|
142 |
-
avg_x = self.post_context(avg_x)
|
143 |
-
avg_x = avg_x.expand_as(out)
|
144 |
-
out = out + avg_x
|
145 |
-
return out
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/ArchitSharma/Digital-Photo-Color-Restoration/src/deoldify/__init__.py
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
from src.deoldify._device import _Device
|
2 |
-
|
3 |
-
device = _Device()
|
|
|
|
|
|
|
|
spaces/Ash58947/Bot/Dockerfile
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
FROM node:18-bullseye-slim
|
2 |
-
|
3 |
-
RUN apt-get update && \
|
4 |
-
|
5 |
-
apt-get install -y git
|
6 |
-
|
7 |
-
RUN git clone https://gitgud.io/khanon/oai-reverse-proxy.git /app
|
8 |
-
|
9 |
-
WORKDIR /app
|
10 |
-
|
11 |
-
RUN npm install
|
12 |
-
|
13 |
-
COPY Dockerfile greeting.md* .env* ./
|
14 |
-
|
15 |
-
RUN npm run build
|
16 |
-
|
17 |
-
EXPOSE 7860
|
18 |
-
|
19 |
-
ENV NODE_ENV=production
|
20 |
-
|
21 |
-
CMD [ "npm", "start" ]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Ataturk-Chatbot/HuggingFaceChat/venv/lib/python3.11/site-packages/pkg_resources/_vendor/importlib_resources/_legacy.py
DELETED
@@ -1,121 +0,0 @@
|
|
1 |
-
import functools
|
2 |
-
import os
|
3 |
-
import pathlib
|
4 |
-
import types
|
5 |
-
import warnings
|
6 |
-
|
7 |
-
from typing import Union, Iterable, ContextManager, BinaryIO, TextIO, Any
|
8 |
-
|
9 |
-
from . import _common
|
10 |
-
|
11 |
-
Package = Union[types.ModuleType, str]
|
12 |
-
Resource = str
|
13 |
-
|
14 |
-
|
15 |
-
def deprecated(func):
|
16 |
-
@functools.wraps(func)
|
17 |
-
def wrapper(*args, **kwargs):
|
18 |
-
warnings.warn(
|
19 |
-
f"{func.__name__} is deprecated. Use files() instead. "
|
20 |
-
"Refer to https://importlib-resources.readthedocs.io"
|
21 |
-
"/en/latest/using.html#migrating-from-legacy for migration advice.",
|
22 |
-
DeprecationWarning,
|
23 |
-
stacklevel=2,
|
24 |
-
)
|
25 |
-
return func(*args, **kwargs)
|
26 |
-
|
27 |
-
return wrapper
|
28 |
-
|
29 |
-
|
30 |
-
def normalize_path(path):
|
31 |
-
# type: (Any) -> str
|
32 |
-
"""Normalize a path by ensuring it is a string.
|
33 |
-
|
34 |
-
If the resulting string contains path separators, an exception is raised.
|
35 |
-
"""
|
36 |
-
str_path = str(path)
|
37 |
-
parent, file_name = os.path.split(str_path)
|
38 |
-
if parent:
|
39 |
-
raise ValueError(f'{path!r} must be only a file name')
|
40 |
-
return file_name
|
41 |
-
|
42 |
-
|
43 |
-
@deprecated
|
44 |
-
def open_binary(package: Package, resource: Resource) -> BinaryIO:
|
45 |
-
"""Return a file-like object opened for binary reading of the resource."""
|
46 |
-
return (_common.files(package) / normalize_path(resource)).open('rb')
|
47 |
-
|
48 |
-
|
49 |
-
@deprecated
|
50 |
-
def read_binary(package: Package, resource: Resource) -> bytes:
|
51 |
-
"""Return the binary contents of the resource."""
|
52 |
-
return (_common.files(package) / normalize_path(resource)).read_bytes()
|
53 |
-
|
54 |
-
|
55 |
-
@deprecated
|
56 |
-
def open_text(
|
57 |
-
package: Package,
|
58 |
-
resource: Resource,
|
59 |
-
encoding: str = 'utf-8',
|
60 |
-
errors: str = 'strict',
|
61 |
-
) -> TextIO:
|
62 |
-
"""Return a file-like object opened for text reading of the resource."""
|
63 |
-
return (_common.files(package) / normalize_path(resource)).open(
|
64 |
-
'r', encoding=encoding, errors=errors
|
65 |
-
)
|
66 |
-
|
67 |
-
|
68 |
-
@deprecated
|
69 |
-
def read_text(
|
70 |
-
package: Package,
|
71 |
-
resource: Resource,
|
72 |
-
encoding: str = 'utf-8',
|
73 |
-
errors: str = 'strict',
|
74 |
-
) -> str:
|
75 |
-
"""Return the decoded string of the resource.
|
76 |
-
|
77 |
-
The decoding-related arguments have the same semantics as those of
|
78 |
-
bytes.decode().
|
79 |
-
"""
|
80 |
-
with open_text(package, resource, encoding, errors) as fp:
|
81 |
-
return fp.read()
|
82 |
-
|
83 |
-
|
84 |
-
@deprecated
|
85 |
-
def contents(package: Package) -> Iterable[str]:
|
86 |
-
"""Return an iterable of entries in `package`.
|
87 |
-
|
88 |
-
Note that not all entries are resources. Specifically, directories are
|
89 |
-
not considered resources. Use `is_resource()` on each entry returned here
|
90 |
-
to check if it is a resource or not.
|
91 |
-
"""
|
92 |
-
return [path.name for path in _common.files(package).iterdir()]
|
93 |
-
|
94 |
-
|
95 |
-
@deprecated
|
96 |
-
def is_resource(package: Package, name: str) -> bool:
|
97 |
-
"""True if `name` is a resource inside `package`.
|
98 |
-
|
99 |
-
Directories are *not* resources.
|
100 |
-
"""
|
101 |
-
resource = normalize_path(name)
|
102 |
-
return any(
|
103 |
-
traversable.name == resource and traversable.is_file()
|
104 |
-
for traversable in _common.files(package).iterdir()
|
105 |
-
)
|
106 |
-
|
107 |
-
|
108 |
-
@deprecated
|
109 |
-
def path(
|
110 |
-
package: Package,
|
111 |
-
resource: Resource,
|
112 |
-
) -> ContextManager[pathlib.Path]:
|
113 |
-
"""A context manager providing a file path object to the resource.
|
114 |
-
|
115 |
-
If the resource does not already exist on its own on the file system,
|
116 |
-
a temporary file will be created. If the file was created, the file
|
117 |
-
will be deleted upon exiting the context manager (no exception is
|
118 |
-
raised if the file was deleted prior to the context manager
|
119 |
-
exiting).
|
120 |
-
"""
|
121 |
-
return _common.as_file(_common.files(package) / normalize_path(resource))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Awiny/Image2Paragraph/models/grit_src/third_party/CenterNet2/tests/structures/test_instances.py
DELETED
@@ -1,219 +0,0 @@
|
|
1 |
-
# Copyright (c) Facebook, Inc. and its affiliates.
|
2 |
-
import unittest
|
3 |
-
import torch
|
4 |
-
from torch import Tensor
|
5 |
-
|
6 |
-
from detectron2.export.torchscript import patch_instances
|
7 |
-
from detectron2.structures import Boxes, Instances
|
8 |
-
from detectron2.utils.testing import convert_scripted_instances
|
9 |
-
|
10 |
-
|
11 |
-
class TestInstances(unittest.TestCase):
|
12 |
-
def test_int_indexing(self):
|
13 |
-
attr1 = torch.tensor([[0.0, 0.0, 1.0], [0.0, 0.0, 0.5], [0.0, 0.0, 1.0], [0.0, 0.5, 0.5]])
|
14 |
-
attr2 = torch.tensor([0.1, 0.2, 0.3, 0.4])
|
15 |
-
instances = Instances((100, 100))
|
16 |
-
instances.attr1 = attr1
|
17 |
-
instances.attr2 = attr2
|
18 |
-
for i in range(-len(instances), len(instances)):
|
19 |
-
inst = instances[i]
|
20 |
-
self.assertEqual((inst.attr1 == attr1[i]).all(), True)
|
21 |
-
self.assertEqual((inst.attr2 == attr2[i]).all(), True)
|
22 |
-
|
23 |
-
self.assertRaises(IndexError, lambda: instances[len(instances)])
|
24 |
-
self.assertRaises(IndexError, lambda: instances[-len(instances) - 1])
|
25 |
-
|
26 |
-
def test_script_new_fields(self):
|
27 |
-
def get_mask(x: Instances) -> torch.Tensor:
|
28 |
-
return x.mask
|
29 |
-
|
30 |
-
class f(torch.nn.Module):
|
31 |
-
def forward(self, x: Instances):
|
32 |
-
proposal_boxes = x.proposal_boxes # noqa F841
|
33 |
-
objectness_logits = x.objectness_logits # noqa F841
|
34 |
-
return x
|
35 |
-
|
36 |
-
class g(torch.nn.Module):
|
37 |
-
def forward(self, x: Instances):
|
38 |
-
return get_mask(x)
|
39 |
-
|
40 |
-
class g2(torch.nn.Module):
|
41 |
-
def __init__(self):
|
42 |
-
super().__init__()
|
43 |
-
self.g = g()
|
44 |
-
|
45 |
-
def forward(self, x: Instances):
|
46 |
-
proposal_boxes = x.proposal_boxes # noqa F841
|
47 |
-
return x, self.g(x)
|
48 |
-
|
49 |
-
fields = {"proposal_boxes": Boxes, "objectness_logits": Tensor}
|
50 |
-
with patch_instances(fields):
|
51 |
-
torch.jit.script(f())
|
52 |
-
|
53 |
-
# can't script anymore after exiting the context
|
54 |
-
with self.assertRaises(Exception):
|
55 |
-
# will create a ConcreteType for g
|
56 |
-
torch.jit.script(g2())
|
57 |
-
|
58 |
-
new_fields = {"mask": Tensor}
|
59 |
-
with patch_instances(new_fields):
|
60 |
-
# will compile g with a different Instances; this should pass
|
61 |
-
torch.jit.script(g())
|
62 |
-
with self.assertRaises(Exception):
|
63 |
-
torch.jit.script(g2())
|
64 |
-
|
65 |
-
new_fields = {"mask": Tensor, "proposal_boxes": Boxes}
|
66 |
-
with patch_instances(new_fields) as NewInstances:
|
67 |
-
# get_mask will be compiled with a different Instances; this should pass
|
68 |
-
scripted_g2 = torch.jit.script(g2())
|
69 |
-
x = NewInstances((3, 4))
|
70 |
-
x.mask = torch.rand(3)
|
71 |
-
x.proposal_boxes = Boxes(torch.rand(3, 4))
|
72 |
-
scripted_g2(x) # it should accept the new Instances object and run successfully
|
73 |
-
|
74 |
-
def test_script_access_fields(self):
|
75 |
-
class f(torch.nn.Module):
|
76 |
-
def forward(self, x: Instances):
|
77 |
-
proposal_boxes = x.proposal_boxes
|
78 |
-
objectness_logits = x.objectness_logits
|
79 |
-
return proposal_boxes.tensor + objectness_logits
|
80 |
-
|
81 |
-
fields = {"proposal_boxes": Boxes, "objectness_logits": Tensor}
|
82 |
-
with patch_instances(fields):
|
83 |
-
torch.jit.script(f())
|
84 |
-
|
85 |
-
def test_script_len(self):
|
86 |
-
class f(torch.nn.Module):
|
87 |
-
def forward(self, x: Instances):
|
88 |
-
return len(x)
|
89 |
-
|
90 |
-
class g(torch.nn.Module):
|
91 |
-
def forward(self, x: Instances):
|
92 |
-
return len(x)
|
93 |
-
|
94 |
-
image_shape = (15, 15)
|
95 |
-
|
96 |
-
fields = {"proposal_boxes": Boxes}
|
97 |
-
with patch_instances(fields) as new_instance:
|
98 |
-
script_module = torch.jit.script(f())
|
99 |
-
x = new_instance(image_shape)
|
100 |
-
with self.assertRaises(Exception):
|
101 |
-
script_module(x)
|
102 |
-
box_tensors = torch.tensor([[5, 5, 10, 10], [1, 1, 2, 3]])
|
103 |
-
x.proposal_boxes = Boxes(box_tensors)
|
104 |
-
length = script_module(x)
|
105 |
-
self.assertEqual(length, 2)
|
106 |
-
|
107 |
-
fields = {"objectness_logits": Tensor}
|
108 |
-
with patch_instances(fields) as new_instance:
|
109 |
-
script_module = torch.jit.script(g())
|
110 |
-
x = new_instance(image_shape)
|
111 |
-
objectness_logits = torch.tensor([1.0]).reshape(1, 1)
|
112 |
-
x.objectness_logits = objectness_logits
|
113 |
-
length = script_module(x)
|
114 |
-
self.assertEqual(length, 1)
|
115 |
-
|
116 |
-
def test_script_has(self):
|
117 |
-
class f(torch.nn.Module):
|
118 |
-
def forward(self, x: Instances):
|
119 |
-
return x.has("proposal_boxes")
|
120 |
-
|
121 |
-
image_shape = (15, 15)
|
122 |
-
fields = {"proposal_boxes": Boxes}
|
123 |
-
with patch_instances(fields) as new_instance:
|
124 |
-
script_module = torch.jit.script(f())
|
125 |
-
x = new_instance(image_shape)
|
126 |
-
self.assertFalse(script_module(x))
|
127 |
-
|
128 |
-
box_tensors = torch.tensor([[5, 5, 10, 10], [1, 1, 2, 3]])
|
129 |
-
x.proposal_boxes = Boxes(box_tensors)
|
130 |
-
self.assertTrue(script_module(x))
|
131 |
-
|
132 |
-
def test_script_to(self):
|
133 |
-
class f(torch.nn.Module):
|
134 |
-
def forward(self, x: Instances):
|
135 |
-
return x.to(torch.device("cpu"))
|
136 |
-
|
137 |
-
image_shape = (15, 15)
|
138 |
-
fields = {"proposal_boxes": Boxes, "a": Tensor}
|
139 |
-
with patch_instances(fields) as new_instance:
|
140 |
-
script_module = torch.jit.script(f())
|
141 |
-
x = new_instance(image_shape)
|
142 |
-
script_module(x)
|
143 |
-
|
144 |
-
box_tensors = torch.tensor([[5, 5, 10, 10], [1, 1, 2, 3]])
|
145 |
-
x.proposal_boxes = Boxes(box_tensors)
|
146 |
-
x.a = box_tensors
|
147 |
-
script_module(x)
|
148 |
-
|
149 |
-
def test_script_getitem(self):
|
150 |
-
class f(torch.nn.Module):
|
151 |
-
def forward(self, x: Instances, idx):
|
152 |
-
return x[idx]
|
153 |
-
|
154 |
-
image_shape = (15, 15)
|
155 |
-
fields = {"proposal_boxes": Boxes, "a": Tensor}
|
156 |
-
inst = Instances(image_shape)
|
157 |
-
inst.proposal_boxes = Boxes(torch.rand(4, 4))
|
158 |
-
inst.a = torch.rand(4, 10)
|
159 |
-
idx = torch.tensor([True, False, True, False])
|
160 |
-
with patch_instances(fields) as new_instance:
|
161 |
-
script_module = torch.jit.script(f())
|
162 |
-
|
163 |
-
out = f()(inst, idx)
|
164 |
-
out_scripted = script_module(new_instance.from_instances(inst), idx)
|
165 |
-
self.assertTrue(
|
166 |
-
torch.equal(out.proposal_boxes.tensor, out_scripted.proposal_boxes.tensor)
|
167 |
-
)
|
168 |
-
self.assertTrue(torch.equal(out.a, out_scripted.a))
|
169 |
-
|
170 |
-
def test_from_to_instances(self):
|
171 |
-
orig = Instances((30, 30))
|
172 |
-
orig.proposal_boxes = Boxes(torch.rand(3, 4))
|
173 |
-
|
174 |
-
fields = {"proposal_boxes": Boxes, "a": Tensor}
|
175 |
-
with patch_instances(fields) as NewInstances:
|
176 |
-
# convert to NewInstances and back
|
177 |
-
new1 = NewInstances.from_instances(orig)
|
178 |
-
new2 = convert_scripted_instances(new1)
|
179 |
-
self.assertTrue(torch.equal(orig.proposal_boxes.tensor, new1.proposal_boxes.tensor))
|
180 |
-
self.assertTrue(torch.equal(orig.proposal_boxes.tensor, new2.proposal_boxes.tensor))
|
181 |
-
|
182 |
-
def test_script_init_args(self):
|
183 |
-
def f(x: Tensor):
|
184 |
-
image_shape = (15, 15)
|
185 |
-
# __init__ can take arguments
|
186 |
-
inst = Instances(image_shape, a=x, proposal_boxes=Boxes(x))
|
187 |
-
inst2 = Instances(image_shape, a=x)
|
188 |
-
return inst.a, inst2.a
|
189 |
-
|
190 |
-
fields = {"proposal_boxes": Boxes, "a": Tensor}
|
191 |
-
with patch_instances(fields):
|
192 |
-
script_f = torch.jit.script(f)
|
193 |
-
x = torch.randn(3, 4)
|
194 |
-
outputs = script_f(x)
|
195 |
-
self.assertTrue(torch.equal(outputs[0], x))
|
196 |
-
self.assertTrue(torch.equal(outputs[1], x))
|
197 |
-
|
198 |
-
def test_script_cat(self):
|
199 |
-
def f(x: Tensor):
|
200 |
-
image_shape = (15, 15)
|
201 |
-
# __init__ can take arguments
|
202 |
-
inst = Instances(image_shape, a=x)
|
203 |
-
inst2 = Instances(image_shape, a=x)
|
204 |
-
|
205 |
-
inst3 = Instances(image_shape, proposal_boxes=Boxes(x))
|
206 |
-
return inst.cat([inst, inst2]), inst3.cat([inst3, inst3])
|
207 |
-
|
208 |
-
fields = {"proposal_boxes": Boxes, "a": Tensor}
|
209 |
-
with patch_instances(fields):
|
210 |
-
script_f = torch.jit.script(f)
|
211 |
-
x = torch.randn(3, 4)
|
212 |
-
output, output2 = script_f(x)
|
213 |
-
self.assertTrue(torch.equal(output.a, torch.cat([x, x])))
|
214 |
-
self.assertFalse(output.has("proposal_boxes"))
|
215 |
-
self.assertTrue(torch.equal(output2.proposal_boxes.tensor, torch.cat([x, x])))
|
216 |
-
|
217 |
-
|
218 |
-
if __name__ == "__main__":
|
219 |
-
unittest.main()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Benson/text-generation/Examples/Carx Calle Pc Descargar Mediafre.md
DELETED
@@ -1,33 +0,0 @@
|
|
1 |
-
<br />
|
2 |
-
<h1>CarX Street PC Descargar Mediafıre: Cómo jugar el último juego de carreras en su computadora</h1>
|
3 |
-
<p>Si eres un fan de los juegos de carreras, es posible que hayas oído hablar de CarX Street, un emocionante juego que te permite explorar el mundo de las carreras nocturnas. Puede recoger coches legendarios, personalizarlos y desafiar a otros jugadores en carreras de red reales. ¿Pero sabías que también puedes jugar CarX Street en tu PC usando Mediafıre? En este artículo, le mostraremos cómo descargar e instalar CarX Street en su computadora usando Mediafıre, y cómo optimizar su experiencia de juego de PC con este increíble juego. ¡Vamos a empezar! </p>
|
4 |
-
<h2>carx calle pc descargar mediafıre</h2><br /><p><b><b>Download</b> ⚹ <a href="https://bltlly.com/2v6ITu">https://bltlly.com/2v6ITu</a></b></p><br /><br />
|
5 |
-
<h2>Introducción</h2>
|
6 |
-
<h3>¿Qué es CarX Street? </h3>
|
7 |
-
<p>CarX Street es un juego de carreras desarrollado por CarX Technologies, LLC. Está disponible para dispositivos Android e iOS, así como para ordenadores Windows y Mac. En CarX Street, puede conducir más de 50 coches oficiales de los mejores fabricantes de automóviles del mundo, como BMW, Toyota, Nissan, Subaru y más. También puede personalizar sus coches con diferentes partes, colores, pegatinas y calcomanías. Puedes correr en varios lugares, desde las concurridas calles de la ciudad hasta las carreteras de montaña en espiral y las carreteras costeras. Puedes desviar, acelerar y esquivar el tráfico mientras compites con otros jugadores en carreras de red reales. También puedes participar en competiciones basadas en historias con múltiples formas de ganar. </p>
|
8 |
-
<h3>¿Por qué jugar CarX Street en PC? </h3>
|
9 |
-
<p>Si bien CarX Street es un gran juego para jugar en tu dispositivo móvil, jugar en tu PC tiene algunas ventajas. Por un lado, se puede disfrutar de los impresionantes gráficos y la física realista del juego en una pantalla más grande. También puede utilizar un controlador o un teclado y ratón para controlar su coche más fácilmente. También puede acceder a miles de aplicaciones y herramientas de productividad en su PC sin cambiar de dispositivo. Jugar CarX Street en PC también le permite ahorrar batería y espacio de almacenamiento en su dispositivo móvil. </p>
|
10 |
-
<h2>Cómo descargar e instalar CarX Street en PC usando Mediafıre</h2>
|
11 |
-
|
12 |
-
<p>Para jugar CarX Street en su PC, tendrá que descargar los archivos del juego desde Mediafıre, un servicio de almacenamiento en la nube que le permite compartir archivos en línea. Puede encontrar el enlace Mediafıre para CarX Street [aquí]( 1 ). Haga clic en el enlace y espere a que comience la descarga. El tamaño del archivo es de aproximadamente 1 GB, por lo que podría tomar algún tiempo dependiendo de su velocidad de Internet. </p>
|
13 |
-
<h3>Paso 2: Extraer el archivo zip y ejecutar el archivo de configuración</h3>
|
14 |
-
<p>Una vez completada la descarga, tendrá que extraer el archivo zip utilizando un programa como WinRAR o 7-Zip. Puede descargar WinRAR [aquí] o 7-Zip [aquí]. Después de extraer el archivo zip, verá una carpeta llamada "CarX_Street". Ábralo y busque el archivo de configuración llamado "CarX_Street_Setup.exe". Haga doble clic en él y espere a que aparezca el asistente de instalación. </p>
|
15 |
-
<p></p>
|
16 |
-
<h3>Paso 3: Siga las instrucciones de instalación y inicie el juego</h3>
|
17 |
-
<p>El asistente de instalación le guiará a través del proceso de instalación de CarX Street en su PC. Deberá aceptar los términos y condiciones, elegir una carpeta de destino y crear un acceso directo al escritorio. La instalación tomará unos minutos, así que ten paciencia. Después de la instalación, puede iniciar el juego haciendo clic en el acceso directo del escritorio o el icono del menú de inicio. Verás el logo de CarX Street y luego el menú principal del juego. </p>
|
18 |
-
<h2>Cómo optimizar tu experiencia de juego en PC con CarX Street</h2>
|
19 |
-
<h3>Ajustar la configuración de gráficos y la resolución</h3>
|
20 |
-
|
21 |
-
<h3>Usa un controlador o un teclado y ratón</h3>
|
22 |
-
<p>Otra forma de optimizar su experiencia de juego de PC con CarX Street es usar un controlador o un teclado y ratón para controlar su automóvil. Puedes usar cualquier mando compatible que se conecte a tu PC a través de USB o Bluetooth, como un mando de Xbox One, PlayStation 4 o Nintendo Switch. También puede utilizar un teclado y un ratón si lo prefiere. Puede personalizar los controles haciendo clic en el icono de engranaje en la esquina superior derecha del menú principal y luego seleccionando la pestaña de controles. Puede asignar diferentes teclas o botones a diferentes acciones, como dirección, aceleración, frenado, deriva, cambio de cámara y más. </p>
|
23 |
-
<h3>Activar el modo multijugador en línea y unirse a otros corredores</h3>
|
24 |
-
<p>La parte más divertida de jugar CarX Street en tu PC es habilitar el modo multijugador en línea y unirse a otros corredores de todo el mundo. Puede acceder al modo multijugador en línea haciendo clic en el icono del globo en la esquina superior izquierda del menú principal. Puede elegir entre diferentes modos, como carrera rápida, carrera clasificada, carrera personalizada o carrera privada. También puede crear o unirse a un club y chatear con otros miembros. Puedes competir con otros jugadores en carreras de red reales y ganar recompensas, puntos de reputación y clasificaciones de clasificación. </p>
|
25 |
-
<h2>Conclusión</h2>
|
26 |
-
<h3>Resumen de los puntos principales</h3>
|
27 |
-
<p>En este artículo, le hemos mostrado cómo jugar CarX Street en su PC usando Mediafıre. Hemos explicado lo que es CarX Street, por qué debe jugar en el PC, cómo descargar e instalar con Mediafıre, y cómo optimizar su experiencia de juego de PC con él. Esperamos que haya encontrado este artículo útil e informativo. </p>
|
28 |
-
<h3>Llamada a la acción y pensamientos finales</h3>
|
29 |
-
|
30 |
-
<p>Gracias por leer este artículo. Si tiene alguna pregunta o comentario, déjelos en la sección de comentarios a continuación. Nos encantaría saber de ti. ¡Feliz carrera! </p>
|
31 |
-
P: ¿CarX Street es libre para jugar? R: Sí, CarX Street es libre para jugar en todas las plataformas. Sin embargo, contiene compras en la aplicación que le permiten comprar moneda premium, automóviles, piezas y otros artículos. P: ¿Es seguro descargar CarX Street desde Mediafıre? R: Sí, CarX Street es seguro para descargar desde Mediafıre siempre y cuando utilice el enlace oficial proporcionado en este artículo. Lo hemos probado nosotros mismos y no encontramos virus o malware. P: ¿Cuáles son los requisitos mínimos del sistema para jugar CarX Street en PC? R: Los requisitos mínimos del sistema para jugar CarX Street en PC son: - OS: Windows 7/8/10 - Procesador: Intel Core i3-4130 / AMD FX-4300 - Memoria: 4 GB RAM - Gráficos: NVIDIA GeForce GTX 660 / AMD Radeon HD 7870 - DirectX: Versión 11 - Almacenamiento: 5 GB de espacio disponible Q: ¿Cómo puedo contactar a los desarrolladores de CarX Street? R: Puede ponerse en contacto con los desarrolladores de CarX Street visitando su sitio web oficial [aquí], su página de Facebook [aquí], su página de Instagram [aquí], o su servidor Discord [aquí]. P: ¿Cómo puedo obtener más información sobre CarX Street? R: Puedes aprender más sobre CarX Street leyendo su blog oficial [ aquí], viendo su canal oficial de YouTube [aquí], o siguiendo su cuenta oficial de Twitter [aquí]. </p> 64aa2da5cf<br />
|
32 |
-
<br />
|
33 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Benson/text-generation/Examples/Descargar Cuentos De Los Hroes Gemelos Valientes (parcheado En Ingls) Iso Psp.md
DELETED
@@ -1,58 +0,0 @@
|
|
1 |
-
|
2 |
-
<h1>Cómo descargar cuentos de los héroes: Twin Brave (parcheado en inglés) ISO PSP</h1>
|
3 |
-
<p>Si eres un fan de la serie <em>Tales</em>, quizás te interese jugar a <strong>Tales of the Heroes: Twin Brave</strong>, un juego spin-off que cuenta con muchos personajes del pasado <em>Tales</em> en un estilo de acción beat 'em up. Sin embargo, hay un problema: este juego solo fue lanzado en Japón para PlayStation Portable (PSP) en 2012, y no hay ninguna localización oficial en inglés. Afortunadamente, hay una manera de jugar este juego en inglés utilizando un parche en inglés no oficial hecho por fans. En este artículo, le mostraremos cómo descargar <strong>Tales of the Heroes: Twin Brave (parcheado en inglés) ISO PSP</strong> y disfrutar jugando en su dispositivo PSP.</p>
|
4 |
-
<h2>Introducción</h2>
|
5 |
-
<p>Antes de entrar en detalles, primero vamos a explicar lo que es <strong>Tales of the Heroes: Twin Brave</strong> y por qué necesitas un parche en inglés para jugarlo. </p>
|
6 |
-
<h2>descargar cuentos de los héroes gemelos valientes (parcheado en inglés) iso psp</h2><br /><p><b><b>DOWNLOAD</b> ★★★★★ <a href="https://bltlly.com/2v6Ldu">https://bltlly.com/2v6Ldu</a></b></p><br /><br />
|
7 |
-
<h3>¿Qué es Cuentos de los Héroes: Twin Brave? </h3>
|
8 |
-
<p><strong>Tales of the Heroes: Twin Brave</strong> es un juego de acción en el <em>Tales <p>Por eso necesitas un parche en inglés, que es una modificación de los archivos del juego que traduce el texto japonés al inglés. Un parche de Inglés es creado por los fans que tienen las habilidades y la pasión para hacer el juego accesible a más personas. Sin embargo, un parche en inglés no es un producto oficial, y puede tener algunos errores o inconsistencias. Por lo tanto, debes usarlo bajo tu propio riesgo y respetar a los creadores originales del juego y el parche. </p>
|
9 |
-
<h3>¿Cuáles son los requisitos para jugar en PSP? </h3>
|
10 |
-
<p>Para jugar <strong>Tales of the Heroes: Twin Brave (parcheado en inglés) ISO PSP</strong> en su dispositivo PSP, necesitará las siguientes cosas:</p>
|
11 |
-
<ul>
|
12 |
-
|
13 |
-
<li>Una tarjeta de memoria que tiene suficiente espacio para almacenar la ISO del juego y el parche en inglés. El juego ISO es de aproximadamente 1,5 GB, y el parche en inglés es de unos 300 MB. También necesitará un poco de espacio adicional para el juego parcheado ISO, que será de aproximadamente 1,8 GB.</li>
|
14 |
-
<li>Un cable USB que puede conectar su PSP a su PC. Necesitará esto para transferir los archivos de su PC a su PSP.</li>
|
15 |
-
</ul>
|
16 |
-
<p>Una vez que tengas estas cosas listas, puedes proceder al siguiente paso. </p>
|
17 |
-
<h2>Paso 1: Descargar el juego ISO y el parche en inglés</h2>
|
18 |
-
<p>El primer paso es descargar el juego ISO y el parche en inglés de fuentes confiables. Puede encontrarlos en varios sitios web, como <a href="">CDRomance</a>, <a href="">Nicoblog</a>, o <a href="">Romhacking.net</a>. Sin embargo, debe tener cuidado ya que algunos sitios web pueden contener malware o virus que pueden dañar su PC o PSP. También deberías revisar los comentarios y reseñas de otros usuarios antes de descargar nada. </p>
|
19 |
-
<p>Después de descargar el juego ISO y el parche en inglés, debe verificar los archivos y extraerlos. Puede utilizar una herramienta como <a href="">7-Zip</a> o <a href="">WinRAR</a> para extraer los archivos de sus formatos comprimidos. También debe usar una herramienta como <a href=">MD5 & SHA Checksum Utility</a> o <a href="">HashTab</a> para verificar las sumas de verificación de los archivos y asegurarse de que no están dañados o manipulados. Las sumas de verificación suelen ser proporcionados por los cargadores de los archivos, y deben coincidir con los que obtiene de su herramienta. </p> <h2>Paso 2: Aplicar el parche en inglés al juego ISO</h2>
|
20 |
-
<p>El siguiente paso es aplicar el parche en inglés a la ISO del juego. Necesitará algunas herramientas para hacer esto, como <a href="">Xdelta</a> o <a href="">PPF-O-Matic</a>. Estas herramientas pueden aplicar un archivo de parche a un archivo de origen y crear un nuevo archivo con los cambios. Puedes encontrar estas herramientas en línea, pero de nuevo, ten cuidado con el malware o los virus. </p>
|
21 |
-
|
22 |
-
<p>Después de parchear el juego ISO, usted debe tener un nuevo archivo que tiene la traducción al inglés aplicado. Puede comprobar el tamaño y el nombre del archivo y compararlo con los dados por los creadores del parche en inglés. También puedes probar la ISO del juego parcheado en tu PC usando un emulador de PSP, como <a href="">PPSSPP</a>, para ver si funciona correctamente y no tiene errores o fallos. </p>
|
23 |
-
<h2>Paso 3: Transferir el juego parcheado ISO a su PSP</h2>
|
24 |
-
<p>El paso final es transferir el juego parcheado ISO a su dispositivo PSP. Tendrá que conectar su PSP a su PC mediante un cable USB. Entonces, tendrá que crear una carpeta para juegos de PSP en su tarjeta de memoria. La carpeta debe llamarse <strong>ISO</strong> y debe estar ubicada en el directorio raíz de su tarjeta de memoria. Si ya tiene esta carpeta, puede omitir este paso. </p>
|
25 |
-
<p></p>
|
26 |
-
<p>A continuación, tendrá que copiar el juego parcheado ISO a su carpeta PSP. Puede utilizar una herramienta como <a href="">Explorador de Windows</a> o <a href=">Total Commander</a> para hacer esto. Debe arrastrar y soltar el archivo ISO del juego parcheado desde su PC a su carpeta PSP. También debe cambiar el nombre del archivo si es demasiado largo o tiene caracteres especiales, ya que esto puede causar problemas en su PSP.</p>
|
27 |
-
<p>Después de copiar el juego parcheado ISO a su carpeta PSP, puede desconectar su PSP de su PC de forma segura. Ahora debería tener el juego parcheado ISO en su tarjeta de memoria, listo para ser jugado en su PSP.</p>
|
28 |
-
<h2>Paso 4: Disfruta jugando Tales of the Heroes: Twin Brave en inglés en tu PSP</h2>
|
29 |
-
<p>El último paso es disfrutar jugando <strong>Tales of the Heroes: Twin Brave en inglés en tu PSP</strong>. Puedes lanzar el juego desde tu menú PSP seleccionando <strong>Game</strong>, luego <strong>Memory Stick</strong>, luego <strong>Tales of the Heroes: Twin Brave</strong>. Deberías ver el logo del juego y escuchar la música del juego. </p>
|
30 |
-
|
31 |
-
<p>Algunos consejos y trucos para jugar el juego son:</p>
|
32 |
-
<ul>
|
33 |
-
<li>Utilice los botones L y R para cambiar entre sus dos caracteres. También puede combinar sus ataques pulsando ambos botones a la vez. </li>
|
34 |
-
<li>Utilice el D-pad para activar habilidades especiales que consumen TP (puntos técnicos). También puede usar elementos que restauran TP o HP (puntos de golpe) presionando hacia arriba o hacia abajo en el D-pad. </li>
|
35 |
-
<li>Usa el stick analógico para moverte y esquivar los ataques enemigos. También puedes usarlo para realizar diferentes tipos de ataques dependiendo de cómo lo inclines. </li>
|
36 |
-
<li>Utilice el botón cuadrado para realizar ataques y combos normales. También puede usarlo para interactuar con objetos o aliados en algunas etapas. </li>
|
37 |
-
<li>Usa el botón de triángulo para realizar ataques de carga que infligen más daño pero te dejan vulnerable. También puedes usarlo para romper guardias o barreras enemigas. </li>
|
38 |
-
<li>Usa el botón circular para realizar ataques aéreos que lanzan enemigos al aire. También puedes usarlo para hacer seguimiento con más ataques en el aire. </li>
|
39 |
-
<li>Utilice el botón X para realizar ataques de guion que se acercan a los enemigos rápidamente. También puede usarlo para evadir ataques enemigos o saltar sobre los obstáculos. </li>
|
40 |
-
<li>Utilice el botón de selección para pausar el juego y acceder al menú. También puede usarlo para saltar escenas o diálogos. </li>
|
41 |
-
<li>Utilice el botón de inicio para activar el modo de ráfaga cuando el medidor de ráfaga esté lleno. El modo de ráfaga aumenta tu ataque y defensa, y te permite realizar un ataque de ráfaga potente presionando el botón de círculo. </li>
|
42 |
-
</ul>
|
43 |
-
<h2>Conclusión</h2>
|
44 |
-
<p>En este artículo, le hemos mostrado cómo descargar <strong>Tales of the Heroes: Twin Brave (parcheado en inglés) ISO PSP</strong> y reproducirlo en su dispositivo PSP. Hemos explicado qué es el juego, por qué necesitas un parche en inglés, cuáles son los requisitos y cómo seguir los pasos para descargar, parchear, transferir y lanzar el juego. También te hemos dado algunas características y modos del juego, y algunos consejos y trucos para jugarlo. </p>
|
45 |
-
|
46 |
-
<h2>Preguntas frecuentes</h2>
|
47 |
-
<h3>Q1: ¿Cuál es la diferencia entre Tales of the Heroes: Twin Brave y Tales of Gekijou? </h3>
|
48 |
-
<p>A1: Tales of Gekijou es una serie de animaciones cortas que se incluyeron como un bono de reserva para Tales of the Heroes: Twin Brave. Presentan versiones chibi de muchos personajes de Tales y no están relacionados con el juego de Tales of the Heroes: Twin Brave.</p>
|
49 |
-
<h3>Q2: ¿Puedo jugar Tales of the Heroes: Twin Brave en otros dispositivos además de PSP? </h3>
|
50 |
-
<p>A2: Sí, puedes jugar Tales of the Heroes: Twin Brave en otros dispositivos como PC, Android o iOS utilizando un emulador de PSP. Sin embargo, tendrás que descargar una versión diferente del juego ISO y el parche en inglés que sean compatibles con tu emulador. </p>
|
51 |
-
<h3>Q3: ¿Cuánto tiempo es Tales of the Heroes: Twin Brave? </h3>
|
52 |
-
<p>A3: Tales of the Heroes: Twin Brave tiene 15 escenarios principales, cada uno con un par de protagonistas de Tales. Cada escenario tiene aproximadamente 10 etapas, y cada etapa tarda unos 5 minutos en completarse. Por lo tanto, le llevará unas 12 horas para terminar todos los escenarios. Sin embargo, también hay misiones adicionales, personajes desbloqueables y modos multijugador que pueden extender tu tiempo de juego. </p>
|
53 |
-
<h3>Q4: ¿Hay una secuela o un remake de Tales of the Heroes: Twin Brave? </h3>
|
54 |
-
<p>A4: No, no hay secuela o un remake de Tales of the Heroes: Twin Brave. Sin embargo, hay otros juegos spin-off en la serie Tales que cuentan con elementos de cruce, como Tales of VS. , Cuentos de Asteria y Cuentos de Link.</p>
|
55 |
-
<h3>Q5: ¿Dónde puedo encontrar más información y recursos sobre Tales of the Heroes: Twin Brave? </h3>
|
56 |
-
<p>A5: Puedes encontrar más información y recursos sobre Tales of the Heroes: Twin Brave en varios sitios web, como Wikipedia, MyAnimeList, GameFAQs y YouTube.</p> 64aa2da5cf<br />
|
57 |
-
<br />
|
58 |
-
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Big-Web/MMSD/env/Lib/site-packages/botocore/regions.py
DELETED
@@ -1,830 +0,0 @@
|
|
1 |
-
# Copyright 2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2 |
-
#
|
3 |
-
# Licensed under the Apache License, Version 2.0 (the "License"). You
|
4 |
-
# may not use this file except in compliance with the License. A copy of
|
5 |
-
# the License is located at
|
6 |
-
#
|
7 |
-
# http://aws.amazon.com/apache2.0/
|
8 |
-
#
|
9 |
-
# or in the "license" file accompanying this file. This file is
|
10 |
-
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
|
11 |
-
# ANY KIND, either express or implied. See the License for the specific
|
12 |
-
# language governing permissions and limitations under the License.
|
13 |
-
"""Resolves regions and endpoints.
|
14 |
-
|
15 |
-
This module implements endpoint resolution, including resolving endpoints for a
|
16 |
-
given service and region and resolving the available endpoints for a service
|
17 |
-
in a specific AWS partition.
|
18 |
-
"""
|
19 |
-
import copy
|
20 |
-
import logging
|
21 |
-
import re
|
22 |
-
from enum import Enum
|
23 |
-
|
24 |
-
from botocore import UNSIGNED, xform_name
|
25 |
-
from botocore.auth import AUTH_TYPE_MAPS, HAS_CRT
|
26 |
-
from botocore.crt import CRT_SUPPORTED_AUTH_TYPES
|
27 |
-
from botocore.endpoint_provider import EndpointProvider
|
28 |
-
from botocore.exceptions import (
|
29 |
-
EndpointProviderError,
|
30 |
-
EndpointVariantError,
|
31 |
-
InvalidEndpointConfigurationError,
|
32 |
-
InvalidHostLabelError,
|
33 |
-
MissingDependencyException,
|
34 |
-
NoRegionError,
|
35 |
-
ParamValidationError,
|
36 |
-
UnknownEndpointResolutionBuiltInName,
|
37 |
-
UnknownRegionError,
|
38 |
-
UnknownSignatureVersionError,
|
39 |
-
UnsupportedS3AccesspointConfigurationError,
|
40 |
-
UnsupportedS3ConfigurationError,
|
41 |
-
UnsupportedS3ControlArnError,
|
42 |
-
UnsupportedS3ControlConfigurationError,
|
43 |
-
)
|
44 |
-
from botocore.utils import ensure_boolean, instance_cache
|
45 |
-
|
46 |
-
LOG = logging.getLogger(__name__)
|
47 |
-
DEFAULT_URI_TEMPLATE = '{service}.{region}.{dnsSuffix}' # noqa
|
48 |
-
DEFAULT_SERVICE_DATA = {'endpoints': {}}
|
49 |
-
|
50 |
-
|
51 |
-
class BaseEndpointResolver:
|
52 |
-
"""Resolves regions and endpoints. Must be subclassed."""
|
53 |
-
|
54 |
-
def construct_endpoint(self, service_name, region_name=None):
|
55 |
-
"""Resolves an endpoint for a service and region combination.
|
56 |
-
|
57 |
-
:type service_name: string
|
58 |
-
:param service_name: Name of the service to resolve an endpoint for
|
59 |
-
(e.g., s3)
|
60 |
-
|
61 |
-
:type region_name: string
|
62 |
-
:param region_name: Region/endpoint name to resolve (e.g., us-east-1)
|
63 |
-
if no region is provided, the first found partition-wide endpoint
|
64 |
-
will be used if available.
|
65 |
-
|
66 |
-
:rtype: dict
|
67 |
-
:return: Returns a dict containing the following keys:
|
68 |
-
- partition: (string, required) Resolved partition name
|
69 |
-
- endpointName: (string, required) Resolved endpoint name
|
70 |
-
- hostname: (string, required) Hostname to use for this endpoint
|
71 |
-
- sslCommonName: (string) sslCommonName to use for this endpoint.
|
72 |
-
- credentialScope: (dict) Signature version 4 credential scope
|
73 |
-
- region: (string) region name override when signing.
|
74 |
-
- service: (string) service name override when signing.
|
75 |
-
- signatureVersions: (list<string>) A list of possible signature
|
76 |
-
versions, including s3, v4, v2, and s3v4
|
77 |
-
- protocols: (list<string>) A list of supported protocols
|
78 |
-
(e.g., http, https)
|
79 |
-
- ...: Other keys may be included as well based on the metadata
|
80 |
-
"""
|
81 |
-
raise NotImplementedError
|
82 |
-
|
83 |
-
def get_available_partitions(self):
|
84 |
-
"""Lists the partitions available to the endpoint resolver.
|
85 |
-
|
86 |
-
:return: Returns a list of partition names (e.g., ["aws", "aws-cn"]).
|
87 |
-
"""
|
88 |
-
raise NotImplementedError
|
89 |
-
|
90 |
-
def get_available_endpoints(
|
91 |
-
self, service_name, partition_name='aws', allow_non_regional=False
|
92 |
-
):
|
93 |
-
"""Lists the endpoint names of a particular partition.
|
94 |
-
|
95 |
-
:type service_name: string
|
96 |
-
:param service_name: Name of a service to list endpoint for (e.g., s3)
|
97 |
-
|
98 |
-
:type partition_name: string
|
99 |
-
:param partition_name: Name of the partition to limit endpoints to.
|
100 |
-
(e.g., aws for the public AWS endpoints, aws-cn for AWS China
|
101 |
-
endpoints, aws-us-gov for AWS GovCloud (US) Endpoints, etc.
|
102 |
-
|
103 |
-
:type allow_non_regional: bool
|
104 |
-
:param allow_non_regional: Set to True to include endpoints that are
|
105 |
-
not regional endpoints (e.g., s3-external-1,
|
106 |
-
fips-us-gov-west-1, etc).
|
107 |
-
:return: Returns a list of endpoint names (e.g., ["us-east-1"]).
|
108 |
-
"""
|
109 |
-
raise NotImplementedError
|
110 |
-
|
111 |
-
|
112 |
-
class EndpointResolver(BaseEndpointResolver):
|
113 |
-
"""Resolves endpoints based on partition endpoint metadata"""
|
114 |
-
|
115 |
-
_UNSUPPORTED_DUALSTACK_PARTITIONS = ['aws-iso', 'aws-iso-b']
|
116 |
-
|
117 |
-
def __init__(self, endpoint_data, uses_builtin_data=False):
|
118 |
-
"""
|
119 |
-
:type endpoint_data: dict
|
120 |
-
:param endpoint_data: A dict of partition data.
|
121 |
-
|
122 |
-
:type uses_builtin_data: boolean
|
123 |
-
:param uses_builtin_data: Whether the endpoint data originates in the
|
124 |
-
package's data directory.
|
125 |
-
"""
|
126 |
-
if 'partitions' not in endpoint_data:
|
127 |
-
raise ValueError('Missing "partitions" in endpoint data')
|
128 |
-
self._endpoint_data = endpoint_data
|
129 |
-
self.uses_builtin_data = uses_builtin_data
|
130 |
-
|
131 |
-
def get_service_endpoints_data(self, service_name, partition_name='aws'):
|
132 |
-
for partition in self._endpoint_data['partitions']:
|
133 |
-
if partition['partition'] != partition_name:
|
134 |
-
continue
|
135 |
-
services = partition['services']
|
136 |
-
if service_name not in services:
|
137 |
-
continue
|
138 |
-
return services[service_name]['endpoints']
|
139 |
-
|
140 |
-
def get_available_partitions(self):
|
141 |
-
result = []
|
142 |
-
for partition in self._endpoint_data['partitions']:
|
143 |
-
result.append(partition['partition'])
|
144 |
-
return result
|
145 |
-
|
146 |
-
def get_available_endpoints(
|
147 |
-
self,
|
148 |
-
service_name,
|
149 |
-
partition_name='aws',
|
150 |
-
allow_non_regional=False,
|
151 |
-
endpoint_variant_tags=None,
|
152 |
-
):
|
153 |
-
result = []
|
154 |
-
for partition in self._endpoint_data['partitions']:
|
155 |
-
if partition['partition'] != partition_name:
|
156 |
-
continue
|
157 |
-
services = partition['services']
|
158 |
-
if service_name not in services:
|
159 |
-
continue
|
160 |
-
service_endpoints = services[service_name]['endpoints']
|
161 |
-
for endpoint_name in service_endpoints:
|
162 |
-
is_regional_endpoint = endpoint_name in partition['regions']
|
163 |
-
# Only regional endpoints can be modeled with variants
|
164 |
-
if endpoint_variant_tags and is_regional_endpoint:
|
165 |
-
variant_data = self._retrieve_variant_data(
|
166 |
-
service_endpoints[endpoint_name], endpoint_variant_tags
|
167 |
-
)
|
168 |
-
if variant_data:
|
169 |
-
result.append(endpoint_name)
|
170 |
-
elif allow_non_regional or is_regional_endpoint:
|
171 |
-
result.append(endpoint_name)
|
172 |
-
return result
|
173 |
-
|
174 |
-
def get_partition_dns_suffix(
|
175 |
-
self, partition_name, endpoint_variant_tags=None
|
176 |
-
):
|
177 |
-
for partition in self._endpoint_data['partitions']:
|
178 |
-
if partition['partition'] == partition_name:
|
179 |
-
if endpoint_variant_tags:
|
180 |
-
variant = self._retrieve_variant_data(
|
181 |
-
partition.get('defaults'), endpoint_variant_tags
|
182 |
-
)
|
183 |
-
if variant and 'dnsSuffix' in variant:
|
184 |
-
return variant['dnsSuffix']
|
185 |
-
else:
|
186 |
-
return partition['dnsSuffix']
|
187 |
-
return None
|
188 |
-
|
189 |
-
def construct_endpoint(
|
190 |
-
self,
|
191 |
-
service_name,
|
192 |
-
region_name=None,
|
193 |
-
partition_name=None,
|
194 |
-
use_dualstack_endpoint=False,
|
195 |
-
use_fips_endpoint=False,
|
196 |
-
):
|
197 |
-
if (
|
198 |
-
service_name == 's3'
|
199 |
-
and use_dualstack_endpoint
|
200 |
-
and region_name is None
|
201 |
-
):
|
202 |
-
region_name = 'us-east-1'
|
203 |
-
|
204 |
-
if partition_name is not None:
|
205 |
-
valid_partition = None
|
206 |
-
for partition in self._endpoint_data['partitions']:
|
207 |
-
if partition['partition'] == partition_name:
|
208 |
-
valid_partition = partition
|
209 |
-
|
210 |
-
if valid_partition is not None:
|
211 |
-
result = self._endpoint_for_partition(
|
212 |
-
valid_partition,
|
213 |
-
service_name,
|
214 |
-
region_name,
|
215 |
-
use_dualstack_endpoint,
|
216 |
-
use_fips_endpoint,
|
217 |
-
True,
|
218 |
-
)
|
219 |
-
return result
|
220 |
-
return None
|
221 |
-
|
222 |
-
# Iterate over each partition until a match is found.
|
223 |
-
for partition in self._endpoint_data['partitions']:
|
224 |
-
if use_dualstack_endpoint and (
|
225 |
-
partition['partition']
|
226 |
-
in self._UNSUPPORTED_DUALSTACK_PARTITIONS
|
227 |
-
):
|
228 |
-
continue
|
229 |
-
result = self._endpoint_for_partition(
|
230 |
-
partition,
|
231 |
-
service_name,
|
232 |
-
region_name,
|
233 |
-
use_dualstack_endpoint,
|
234 |
-
use_fips_endpoint,
|
235 |
-
)
|
236 |
-
if result:
|
237 |
-
return result
|
238 |
-
|
239 |
-
def get_partition_for_region(self, region_name):
|
240 |
-
for partition in self._endpoint_data['partitions']:
|
241 |
-
if self._region_match(partition, region_name):
|
242 |
-
return partition['partition']
|
243 |
-
raise UnknownRegionError(
|
244 |
-
region_name=region_name,
|
245 |
-
error_msg='No partition found for provided region_name.',
|
246 |
-
)
|
247 |
-
|
248 |
-
def _endpoint_for_partition(
|
249 |
-
self,
|
250 |
-
partition,
|
251 |
-
service_name,
|
252 |
-
region_name,
|
253 |
-
use_dualstack_endpoint,
|
254 |
-
use_fips_endpoint,
|
255 |
-
force_partition=False,
|
256 |
-
):
|
257 |
-
partition_name = partition["partition"]
|
258 |
-
if (
|
259 |
-
use_dualstack_endpoint
|
260 |
-
and partition_name in self._UNSUPPORTED_DUALSTACK_PARTITIONS
|
261 |
-
):
|
262 |
-
error_msg = (
|
263 |
-
"Dualstack endpoints are currently not supported"
|
264 |
-
" for %s partition" % partition_name
|
265 |
-
)
|
266 |
-
raise EndpointVariantError(tags=['dualstack'], error_msg=error_msg)
|
267 |
-
|
268 |
-
# Get the service from the partition, or an empty template.
|
269 |
-
service_data = partition['services'].get(
|
270 |
-
service_name, DEFAULT_SERVICE_DATA
|
271 |
-
)
|
272 |
-
# Use the partition endpoint if no region is supplied.
|
273 |
-
if region_name is None:
|
274 |
-
if 'partitionEndpoint' in service_data:
|
275 |
-
region_name = service_data['partitionEndpoint']
|
276 |
-
else:
|
277 |
-
raise NoRegionError()
|
278 |
-
|
279 |
-
resolve_kwargs = {
|
280 |
-
'partition': partition,
|
281 |
-
'service_name': service_name,
|
282 |
-
'service_data': service_data,
|
283 |
-
'endpoint_name': region_name,
|
284 |
-
'use_dualstack_endpoint': use_dualstack_endpoint,
|
285 |
-
'use_fips_endpoint': use_fips_endpoint,
|
286 |
-
}
|
287 |
-
|
288 |
-
# Attempt to resolve the exact region for this partition.
|
289 |
-
if region_name in service_data['endpoints']:
|
290 |
-
return self._resolve(**resolve_kwargs)
|
291 |
-
|
292 |
-
# Check to see if the endpoint provided is valid for the partition.
|
293 |
-
if self._region_match(partition, region_name) or force_partition:
|
294 |
-
# Use the partition endpoint if set and not regionalized.
|
295 |
-
partition_endpoint = service_data.get('partitionEndpoint')
|
296 |
-
is_regionalized = service_data.get('isRegionalized', True)
|
297 |
-
if partition_endpoint and not is_regionalized:
|
298 |
-
LOG.debug(
|
299 |
-
'Using partition endpoint for %s, %s: %s',
|
300 |
-
service_name,
|
301 |
-
region_name,
|
302 |
-
partition_endpoint,
|
303 |
-
)
|
304 |
-
resolve_kwargs['endpoint_name'] = partition_endpoint
|
305 |
-
return self._resolve(**resolve_kwargs)
|
306 |
-
LOG.debug(
|
307 |
-
'Creating a regex based endpoint for %s, %s',
|
308 |
-
service_name,
|
309 |
-
region_name,
|
310 |
-
)
|
311 |
-
return self._resolve(**resolve_kwargs)
|
312 |
-
|
313 |
-
def _region_match(self, partition, region_name):
|
314 |
-
if region_name in partition['regions']:
|
315 |
-
return True
|
316 |
-
if 'regionRegex' in partition:
|
317 |
-
return re.compile(partition['regionRegex']).match(region_name)
|
318 |
-
return False
|
319 |
-
|
320 |
-
def _retrieve_variant_data(self, endpoint_data, tags):
|
321 |
-
variants = endpoint_data.get('variants', [])
|
322 |
-
for variant in variants:
|
323 |
-
if set(variant['tags']) == set(tags):
|
324 |
-
result = variant.copy()
|
325 |
-
return result
|
326 |
-
|
327 |
-
def _create_tag_list(self, use_dualstack_endpoint, use_fips_endpoint):
|
328 |
-
tags = []
|
329 |
-
if use_dualstack_endpoint:
|
330 |
-
tags.append('dualstack')
|
331 |
-
if use_fips_endpoint:
|
332 |
-
tags.append('fips')
|
333 |
-
return tags
|
334 |
-
|
335 |
-
def _resolve_variant(
|
336 |
-
self, tags, endpoint_data, service_defaults, partition_defaults
|
337 |
-
):
|
338 |
-
result = {}
|
339 |
-
for variants in [endpoint_data, service_defaults, partition_defaults]:
|
340 |
-
variant = self._retrieve_variant_data(variants, tags)
|
341 |
-
if variant:
|
342 |
-
self._merge_keys(variant, result)
|
343 |
-
return result
|
344 |
-
|
345 |
-
def _resolve(
|
346 |
-
self,
|
347 |
-
partition,
|
348 |
-
service_name,
|
349 |
-
service_data,
|
350 |
-
endpoint_name,
|
351 |
-
use_dualstack_endpoint,
|
352 |
-
use_fips_endpoint,
|
353 |
-
):
|
354 |
-
endpoint_data = service_data.get('endpoints', {}).get(
|
355 |
-
endpoint_name, {}
|
356 |
-
)
|
357 |
-
|
358 |
-
if endpoint_data.get('deprecated'):
|
359 |
-
LOG.warning(
|
360 |
-
'Client is configured with the deprecated endpoint: %s'
|
361 |
-
% (endpoint_name)
|
362 |
-
)
|
363 |
-
|
364 |
-
service_defaults = service_data.get('defaults', {})
|
365 |
-
partition_defaults = partition.get('defaults', {})
|
366 |
-
tags = self._create_tag_list(use_dualstack_endpoint, use_fips_endpoint)
|
367 |
-
|
368 |
-
if tags:
|
369 |
-
result = self._resolve_variant(
|
370 |
-
tags, endpoint_data, service_defaults, partition_defaults
|
371 |
-
)
|
372 |
-
if result == {}:
|
373 |
-
error_msg = (
|
374 |
-
f"Endpoint does not exist for {service_name} "
|
375 |
-
f"in region {endpoint_name}"
|
376 |
-
)
|
377 |
-
raise EndpointVariantError(tags=tags, error_msg=error_msg)
|
378 |
-
self._merge_keys(endpoint_data, result)
|
379 |
-
else:
|
380 |
-
result = endpoint_data
|
381 |
-
|
382 |
-
# If dnsSuffix has not already been consumed from a variant definition
|
383 |
-
if 'dnsSuffix' not in result:
|
384 |
-
result['dnsSuffix'] = partition['dnsSuffix']
|
385 |
-
|
386 |
-
result['partition'] = partition['partition']
|
387 |
-
result['endpointName'] = endpoint_name
|
388 |
-
|
389 |
-
# Merge in the service defaults then the partition defaults.
|
390 |
-
self._merge_keys(service_defaults, result)
|
391 |
-
self._merge_keys(partition_defaults, result)
|
392 |
-
|
393 |
-
result['hostname'] = self._expand_template(
|
394 |
-
partition,
|
395 |
-
result['hostname'],
|
396 |
-
service_name,
|
397 |
-
endpoint_name,
|
398 |
-
result['dnsSuffix'],
|
399 |
-
)
|
400 |
-
if 'sslCommonName' in result:
|
401 |
-
result['sslCommonName'] = self._expand_template(
|
402 |
-
partition,
|
403 |
-
result['sslCommonName'],
|
404 |
-
service_name,
|
405 |
-
endpoint_name,
|
406 |
-
result['dnsSuffix'],
|
407 |
-
)
|
408 |
-
|
409 |
-
return result
|
410 |
-
|
411 |
-
def _merge_keys(self, from_data, result):
|
412 |
-
for key in from_data:
|
413 |
-
if key not in result:
|
414 |
-
result[key] = from_data[key]
|
415 |
-
|
416 |
-
def _expand_template(
|
417 |
-
self, partition, template, service_name, endpoint_name, dnsSuffix
|
418 |
-
):
|
419 |
-
return template.format(
|
420 |
-
service=service_name, region=endpoint_name, dnsSuffix=dnsSuffix
|
421 |
-
)
|
422 |
-
|
423 |
-
|
424 |
-
class EndpointResolverBuiltins(str, Enum):
|
425 |
-
# The AWS Region configured for the SDK client (str)
|
426 |
-
AWS_REGION = "AWS::Region"
|
427 |
-
# Whether the UseFIPSEndpoint configuration option has been enabled for
|
428 |
-
# the SDK client (bool)
|
429 |
-
AWS_USE_FIPS = "AWS::UseFIPS"
|
430 |
-
# Whether the UseDualStackEndpoint configuration option has been enabled
|
431 |
-
# for the SDK client (bool)
|
432 |
-
AWS_USE_DUALSTACK = "AWS::UseDualStack"
|
433 |
-
# Whether the global endpoint should be used with STS, rather the the
|
434 |
-
# regional endpoint for us-east-1 (bool)
|
435 |
-
AWS_STS_USE_GLOBAL_ENDPOINT = "AWS::STS::UseGlobalEndpoint"
|
436 |
-
# Whether the global endpoint should be used with S3, rather then the
|
437 |
-
# regional endpoint for us-east-1 (bool)
|
438 |
-
AWS_S3_USE_GLOBAL_ENDPOINT = "AWS::S3::UseGlobalEndpoint"
|
439 |
-
# Whether S3 Transfer Acceleration has been requested (bool)
|
440 |
-
AWS_S3_ACCELERATE = "AWS::S3::Accelerate"
|
441 |
-
# Whether S3 Force Path Style has been enabled (bool)
|
442 |
-
AWS_S3_FORCE_PATH_STYLE = "AWS::S3::ForcePathStyle"
|
443 |
-
# Whether to use the ARN region or raise an error when ARN and client
|
444 |
-
# region differ (for s3 service only, bool)
|
445 |
-
AWS_S3_USE_ARN_REGION = "AWS::S3::UseArnRegion"
|
446 |
-
# Whether to use the ARN region or raise an error when ARN and client
|
447 |
-
# region differ (for s3-control service only, bool)
|
448 |
-
AWS_S3CONTROL_USE_ARN_REGION = 'AWS::S3Control::UseArnRegion'
|
449 |
-
# Whether multi-region access points (MRAP) should be disabled (bool)
|
450 |
-
AWS_S3_DISABLE_MRAP = "AWS::S3::DisableMultiRegionAccessPoints"
|
451 |
-
# Whether a custom endpoint has been configured (str)
|
452 |
-
SDK_ENDPOINT = "SDK::Endpoint"
|
453 |
-
|
454 |
-
|
455 |
-
class EndpointRulesetResolver:
|
456 |
-
"""Resolves endpoints using a service's endpoint ruleset"""
|
457 |
-
|
458 |
-
def __init__(
|
459 |
-
self,
|
460 |
-
endpoint_ruleset_data,
|
461 |
-
partition_data,
|
462 |
-
service_model,
|
463 |
-
builtins,
|
464 |
-
client_context,
|
465 |
-
event_emitter,
|
466 |
-
use_ssl=True,
|
467 |
-
requested_auth_scheme=None,
|
468 |
-
):
|
469 |
-
self._provider = EndpointProvider(
|
470 |
-
ruleset_data=endpoint_ruleset_data,
|
471 |
-
partition_data=partition_data,
|
472 |
-
)
|
473 |
-
self._param_definitions = self._provider.ruleset.parameters
|
474 |
-
self._service_model = service_model
|
475 |
-
self._builtins = builtins
|
476 |
-
self._client_context = client_context
|
477 |
-
self._event_emitter = event_emitter
|
478 |
-
self._use_ssl = use_ssl
|
479 |
-
self._requested_auth_scheme = requested_auth_scheme
|
480 |
-
self._instance_cache = {}
|
481 |
-
|
482 |
-
def construct_endpoint(
|
483 |
-
self,
|
484 |
-
operation_model,
|
485 |
-
call_args,
|
486 |
-
request_context,
|
487 |
-
):
|
488 |
-
"""Invokes the provider with params defined in the service's ruleset"""
|
489 |
-
if call_args is None:
|
490 |
-
call_args = {}
|
491 |
-
|
492 |
-
if request_context is None:
|
493 |
-
request_context = {}
|
494 |
-
|
495 |
-
provider_params = self._get_provider_params(
|
496 |
-
operation_model, call_args, request_context
|
497 |
-
)
|
498 |
-
LOG.debug(
|
499 |
-
'Calling endpoint provider with parameters: %s' % provider_params
|
500 |
-
)
|
501 |
-
try:
|
502 |
-
provider_result = self._provider.resolve_endpoint(
|
503 |
-
**provider_params
|
504 |
-
)
|
505 |
-
except EndpointProviderError as ex:
|
506 |
-
botocore_exception = self.ruleset_error_to_botocore_exception(
|
507 |
-
ex, provider_params
|
508 |
-
)
|
509 |
-
if botocore_exception is None:
|
510 |
-
raise
|
511 |
-
else:
|
512 |
-
raise botocore_exception from ex
|
513 |
-
LOG.debug('Endpoint provider result: %s' % provider_result.url)
|
514 |
-
|
515 |
-
# The endpoint provider does not support non-secure transport.
|
516 |
-
if not self._use_ssl and provider_result.url.startswith('https://'):
|
517 |
-
provider_result = provider_result._replace(
|
518 |
-
url=f'http://{provider_result.url[8:]}'
|
519 |
-
)
|
520 |
-
|
521 |
-
# Multi-valued headers are not supported in botocore. Replace the list
|
522 |
-
# of values returned for each header with just its first entry,
|
523 |
-
# dropping any additionally entries.
|
524 |
-
provider_result = provider_result._replace(
|
525 |
-
headers={
|
526 |
-
key: val[0] for key, val in provider_result.headers.items()
|
527 |
-
}
|
528 |
-
)
|
529 |
-
|
530 |
-
return provider_result
|
531 |
-
|
532 |
-
def _get_provider_params(
|
533 |
-
self, operation_model, call_args, request_context
|
534 |
-
):
|
535 |
-
"""Resolve a value for each parameter defined in the service's ruleset
|
536 |
-
|
537 |
-
The resolution order for parameter values is:
|
538 |
-
1. Operation-specific static context values from the service definition
|
539 |
-
2. Operation-specific dynamic context values from API parameters
|
540 |
-
3. Client-specific context parameters
|
541 |
-
4. Built-in values such as region, FIPS usage, ...
|
542 |
-
"""
|
543 |
-
provider_params = {}
|
544 |
-
# Builtin values can be customized for each operation by hooks
|
545 |
-
# subscribing to the ``before-endpoint-resolution.*`` event.
|
546 |
-
customized_builtins = self._get_customized_builtins(
|
547 |
-
operation_model, call_args, request_context
|
548 |
-
)
|
549 |
-
for param_name, param_def in self._param_definitions.items():
|
550 |
-
param_val = self._resolve_param_from_context(
|
551 |
-
param_name=param_name,
|
552 |
-
operation_model=operation_model,
|
553 |
-
call_args=call_args,
|
554 |
-
)
|
555 |
-
if param_val is None and param_def.builtin is not None:
|
556 |
-
param_val = self._resolve_param_as_builtin(
|
557 |
-
builtin_name=param_def.builtin,
|
558 |
-
builtins=customized_builtins,
|
559 |
-
)
|
560 |
-
if param_val is not None:
|
561 |
-
provider_params[param_name] = param_val
|
562 |
-
|
563 |
-
return provider_params
|
564 |
-
|
565 |
-
def _resolve_param_from_context(
|
566 |
-
self, param_name, operation_model, call_args
|
567 |
-
):
|
568 |
-
static = self._resolve_param_as_static_context_param(
|
569 |
-
param_name, operation_model
|
570 |
-
)
|
571 |
-
if static is not None:
|
572 |
-
return static
|
573 |
-
dynamic = self._resolve_param_as_dynamic_context_param(
|
574 |
-
param_name, operation_model, call_args
|
575 |
-
)
|
576 |
-
if dynamic is not None:
|
577 |
-
return dynamic
|
578 |
-
return self._resolve_param_as_client_context_param(param_name)
|
579 |
-
|
580 |
-
def _resolve_param_as_static_context_param(
|
581 |
-
self, param_name, operation_model
|
582 |
-
):
|
583 |
-
static_ctx_params = self._get_static_context_params(operation_model)
|
584 |
-
return static_ctx_params.get(param_name)
|
585 |
-
|
586 |
-
def _resolve_param_as_dynamic_context_param(
|
587 |
-
self, param_name, operation_model, call_args
|
588 |
-
):
|
589 |
-
dynamic_ctx_params = self._get_dynamic_context_params(operation_model)
|
590 |
-
if param_name in dynamic_ctx_params:
|
591 |
-
member_name = dynamic_ctx_params[param_name]
|
592 |
-
return call_args.get(member_name)
|
593 |
-
|
594 |
-
def _resolve_param_as_client_context_param(self, param_name):
|
595 |
-
client_ctx_params = self._get_client_context_params()
|
596 |
-
if param_name in client_ctx_params:
|
597 |
-
client_ctx_varname = client_ctx_params[param_name]
|
598 |
-
return self._client_context.get(client_ctx_varname)
|
599 |
-
|
600 |
-
def _resolve_param_as_builtin(self, builtin_name, builtins):
|
601 |
-
if builtin_name not in EndpointResolverBuiltins.__members__.values():
|
602 |
-
raise UnknownEndpointResolutionBuiltInName(name=builtin_name)
|
603 |
-
return builtins.get(builtin_name)
|
604 |
-
|
605 |
-
@instance_cache
|
606 |
-
def _get_static_context_params(self, operation_model):
|
607 |
-
"""Mapping of param names to static param value for an operation"""
|
608 |
-
return {
|
609 |
-
param.name: param.value
|
610 |
-
for param in operation_model.static_context_parameters
|
611 |
-
}
|
612 |
-
|
613 |
-
@instance_cache
|
614 |
-
def _get_dynamic_context_params(self, operation_model):
|
615 |
-
"""Mapping of param names to member names for an operation"""
|
616 |
-
return {
|
617 |
-
param.name: param.member_name
|
618 |
-
for param in operation_model.context_parameters
|
619 |
-
}
|
620 |
-
|
621 |
-
@instance_cache
|
622 |
-
def _get_client_context_params(self):
|
623 |
-
"""Mapping of param names to client configuration variable"""
|
624 |
-
return {
|
625 |
-
param.name: xform_name(param.name)
|
626 |
-
for param in self._service_model.client_context_parameters
|
627 |
-
}
|
628 |
-
|
629 |
-
def _get_customized_builtins(
|
630 |
-
self, operation_model, call_args, request_context
|
631 |
-
):
|
632 |
-
service_id = self._service_model.service_id.hyphenize()
|
633 |
-
customized_builtins = copy.copy(self._builtins)
|
634 |
-
# Handlers are expected to modify the builtins dict in place.
|
635 |
-
self._event_emitter.emit(
|
636 |
-
'before-endpoint-resolution.%s' % service_id,
|
637 |
-
builtins=customized_builtins,
|
638 |
-
model=operation_model,
|
639 |
-
params=call_args,
|
640 |
-
context=request_context,
|
641 |
-
)
|
642 |
-
return customized_builtins
|
643 |
-
|
644 |
-
def auth_schemes_to_signing_ctx(self, auth_schemes):
|
645 |
-
"""Convert an Endpoint's authSchemes property to a signing_context dict
|
646 |
-
|
647 |
-
:type auth_schemes: list
|
648 |
-
:param auth_schemes: A list of dictionaries taken from the
|
649 |
-
``authSchemes`` property of an Endpoint object returned by
|
650 |
-
``EndpointProvider``.
|
651 |
-
|
652 |
-
:rtype: str, dict
|
653 |
-
:return: Tuple of auth type string (to be used in
|
654 |
-
``request_context['auth_type']``) and signing context dict (for use
|
655 |
-
in ``request_context['signing']``).
|
656 |
-
"""
|
657 |
-
if not isinstance(auth_schemes, list) or len(auth_schemes) == 0:
|
658 |
-
raise TypeError("auth_schemes must be a non-empty list.")
|
659 |
-
|
660 |
-
LOG.debug(
|
661 |
-
'Selecting from endpoint provider\'s list of auth schemes: %s. '
|
662 |
-
'User selected auth scheme is: "%s"',
|
663 |
-
', '.join([f'"{s.get("name")}"' for s in auth_schemes]),
|
664 |
-
self._requested_auth_scheme,
|
665 |
-
)
|
666 |
-
|
667 |
-
if self._requested_auth_scheme == UNSIGNED:
|
668 |
-
return 'none', {}
|
669 |
-
|
670 |
-
auth_schemes = [
|
671 |
-
{**scheme, 'name': self._strip_sig_prefix(scheme['name'])}
|
672 |
-
for scheme in auth_schemes
|
673 |
-
]
|
674 |
-
if self._requested_auth_scheme is not None:
|
675 |
-
try:
|
676 |
-
# Use the first scheme that matches the requested scheme,
|
677 |
-
# after accounting for naming differences between botocore and
|
678 |
-
# endpoint rulesets. Keep the requested name.
|
679 |
-
name, scheme = next(
|
680 |
-
(self._requested_auth_scheme, s)
|
681 |
-
for s in auth_schemes
|
682 |
-
if self._does_botocore_authname_match_ruleset_authname(
|
683 |
-
self._requested_auth_scheme, s['name']
|
684 |
-
)
|
685 |
-
)
|
686 |
-
except StopIteration:
|
687 |
-
# For legacy signers, no match will be found. Do not raise an
|
688 |
-
# exception, instead default to the logic in botocore
|
689 |
-
# customizations.
|
690 |
-
return None, {}
|
691 |
-
else:
|
692 |
-
try:
|
693 |
-
name, scheme = next(
|
694 |
-
(s['name'], s)
|
695 |
-
for s in auth_schemes
|
696 |
-
if s['name'] in AUTH_TYPE_MAPS
|
697 |
-
)
|
698 |
-
except StopIteration:
|
699 |
-
# If no auth scheme was specifically requested and an
|
700 |
-
# authSchemes list is present in the Endpoint object but none
|
701 |
-
# of the entries are supported, raise an exception.
|
702 |
-
fixable_with_crt = False
|
703 |
-
auth_type_options = [s['name'] for s in auth_schemes]
|
704 |
-
if not HAS_CRT:
|
705 |
-
fixable_with_crt = any(
|
706 |
-
scheme in CRT_SUPPORTED_AUTH_TYPES
|
707 |
-
for scheme in auth_type_options
|
708 |
-
)
|
709 |
-
|
710 |
-
if fixable_with_crt:
|
711 |
-
raise MissingDependencyException(
|
712 |
-
msg='This operation requires an additional dependency.'
|
713 |
-
' Use pip install botocore[crt] before proceeding.'
|
714 |
-
)
|
715 |
-
else:
|
716 |
-
raise UnknownSignatureVersionError(
|
717 |
-
signature_version=', '.join(auth_type_options)
|
718 |
-
)
|
719 |
-
|
720 |
-
signing_context = {}
|
721 |
-
if 'signingRegion' in scheme:
|
722 |
-
signing_context['region'] = scheme['signingRegion']
|
723 |
-
elif 'signingRegionSet' in scheme:
|
724 |
-
if len(scheme['signingRegionSet']) > 0:
|
725 |
-
signing_context['region'] = scheme['signingRegionSet'][0]
|
726 |
-
if 'signingName' in scheme:
|
727 |
-
signing_context.update(signing_name=scheme['signingName'])
|
728 |
-
if 'disableDoubleEncoding' in scheme:
|
729 |
-
signing_context['disableDoubleEncoding'] = ensure_boolean(
|
730 |
-
scheme['disableDoubleEncoding']
|
731 |
-
)
|
732 |
-
|
733 |
-
LOG.debug(
|
734 |
-
'Selected auth type "%s" as "%s" with signing context params: %s',
|
735 |
-
scheme['name'], # original name without "sig"
|
736 |
-
name, # chosen name can differ when `signature_version` is set
|
737 |
-
signing_context,
|
738 |
-
)
|
739 |
-
return name, signing_context
|
740 |
-
|
741 |
-
def _strip_sig_prefix(self, auth_name):
|
742 |
-
"""Normalize auth type names by removing any "sig" prefix"""
|
743 |
-
return auth_name[3:] if auth_name.startswith('sig') else auth_name
|
744 |
-
|
745 |
-
def _does_botocore_authname_match_ruleset_authname(self, botoname, rsname):
|
746 |
-
"""
|
747 |
-
Whether a valid string provided as signature_version parameter for
|
748 |
-
client construction refers to the same auth methods as a string
|
749 |
-
returned by the endpoint ruleset provider. This accounts for:
|
750 |
-
|
751 |
-
* The ruleset prefixes auth names with "sig"
|
752 |
-
* The s3 and s3control rulesets don't distinguish between v4[a] and
|
753 |
-
s3v4[a] signers
|
754 |
-
* The v2, v3, and HMAC v1 based signers (s3, s3-*) are botocore legacy
|
755 |
-
features and do not exist in the rulesets
|
756 |
-
* Only characters up to the first dash are considered
|
757 |
-
|
758 |
-
Example matches:
|
759 |
-
* v4, sigv4
|
760 |
-
* v4, v4
|
761 |
-
* s3v4, sigv4
|
762 |
-
* s3v7, sigv7 (hypothetical example)
|
763 |
-
* s3v4a, sigv4a
|
764 |
-
* s3v4-query, sigv4
|
765 |
-
|
766 |
-
Example mismatches:
|
767 |
-
* v4a, sigv4
|
768 |
-
* s3, sigv4
|
769 |
-
* s3-presign-post, sigv4
|
770 |
-
"""
|
771 |
-
rsname = self._strip_sig_prefix(rsname)
|
772 |
-
botoname = botoname.split('-')[0]
|
773 |
-
if botoname != 's3' and botoname.startswith('s3'):
|
774 |
-
botoname = botoname[2:]
|
775 |
-
return rsname == botoname
|
776 |
-
|
777 |
-
def ruleset_error_to_botocore_exception(self, ruleset_exception, params):
|
778 |
-
"""Attempts to translate ruleset errors to pre-existing botocore
|
779 |
-
exception types by string matching exception strings.
|
780 |
-
"""
|
781 |
-
msg = ruleset_exception.kwargs.get('msg')
|
782 |
-
if msg is None:
|
783 |
-
return
|
784 |
-
|
785 |
-
if msg.startswith('Invalid region in ARN: '):
|
786 |
-
# Example message:
|
787 |
-
# "Invalid region in ARN: `us-we$t-2` (invalid DNS name)"
|
788 |
-
try:
|
789 |
-
label = msg.split('`')[1]
|
790 |
-
except IndexError:
|
791 |
-
label = msg
|
792 |
-
return InvalidHostLabelError(label=label)
|
793 |
-
|
794 |
-
service_name = self._service_model.service_name
|
795 |
-
if service_name == 's3':
|
796 |
-
if (
|
797 |
-
msg == 'S3 Object Lambda does not support S3 Accelerate'
|
798 |
-
or msg == 'Accelerate cannot be used with FIPS'
|
799 |
-
):
|
800 |
-
return UnsupportedS3ConfigurationError(msg=msg)
|
801 |
-
if (
|
802 |
-
msg.startswith('S3 Outposts does not support')
|
803 |
-
or msg.startswith('S3 MRAP does not support')
|
804 |
-
or msg.startswith('S3 Object Lambda does not support')
|
805 |
-
or msg.startswith('Access Points do not support')
|
806 |
-
or msg.startswith('Invalid configuration:')
|
807 |
-
or msg.startswith('Client was configured for partition')
|
808 |
-
):
|
809 |
-
return UnsupportedS3AccesspointConfigurationError(msg=msg)
|
810 |
-
if msg.lower().startswith('invalid arn:'):
|
811 |
-
return ParamValidationError(report=msg)
|
812 |
-
if service_name == 's3control':
|
813 |
-
if msg.startswith('Invalid ARN:'):
|
814 |
-
arn = params.get('Bucket')
|
815 |
-
return UnsupportedS3ControlArnError(arn=arn, msg=msg)
|
816 |
-
if msg.startswith('Invalid configuration:') or msg.startswith(
|
817 |
-
'Client was configured for partition'
|
818 |
-
):
|
819 |
-
return UnsupportedS3ControlConfigurationError(msg=msg)
|
820 |
-
if msg == "AccountId is required but not set":
|
821 |
-
return ParamValidationError(report=msg)
|
822 |
-
if service_name == 'events':
|
823 |
-
if msg.startswith(
|
824 |
-
'Invalid Configuration: FIPS is not supported with '
|
825 |
-
'EventBridge multi-region endpoints.'
|
826 |
-
):
|
827 |
-
return InvalidEndpointConfigurationError(msg=msg)
|
828 |
-
if msg == 'EndpointId must be a valid host label.':
|
829 |
-
return InvalidEndpointConfigurationError(msg=msg)
|
830 |
-
return None
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/BigBoyBranding/README/README.md
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
---
|
2 |
-
title: README
|
3 |
-
emoji: 🏃
|
4 |
-
colorFrom: red
|
5 |
-
colorTo: indigo
|
6 |
-
sdk: static
|
7 |
-
pinned: false
|
8 |
-
---
|
9 |
-
|
10 |
-
Big Bird's Ballsack
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CVPR/Dual-Key_Backdoor_Attacks/datagen/detectron2/tools/README.md
DELETED
@@ -1,45 +0,0 @@
|
|
1 |
-
|
2 |
-
This directory contains a few scripts that use detectron2.
|
3 |
-
|
4 |
-
|
5 |
-
* `train_net.py`
|
6 |
-
|
7 |
-
An example training script that's made to train builtin models of detectron2.
|
8 |
-
|
9 |
-
For usage, see [GETTING_STARTED.md](../GETTING_STARTED.md).
|
10 |
-
|
11 |
-
* `plain_train_net.py`
|
12 |
-
|
13 |
-
Similar to `train_net.py`, but implements a training loop instead of using `Trainer`.
|
14 |
-
This script includes fewer features but it may be more friendly to hackers.
|
15 |
-
|
16 |
-
* `benchmark.py`
|
17 |
-
|
18 |
-
Benchmark the training speed, inference speed or data loading speed of a given config.
|
19 |
-
|
20 |
-
Usage:
|
21 |
-
```
|
22 |
-
python benchmark.py --config-file config.yaml --task train/eval/data [optional DDP flags]
|
23 |
-
```
|
24 |
-
|
25 |
-
* `visualize_json_results.py`
|
26 |
-
|
27 |
-
Visualize the json instance detection/segmentation results dumped by `COCOEvalutor` or `LVISEvaluator`
|
28 |
-
|
29 |
-
Usage:
|
30 |
-
```
|
31 |
-
python visualize_json_results.py --input x.json --output dir/ --dataset coco_2017_val
|
32 |
-
```
|
33 |
-
If not using a builtin dataset, you'll need your own script or modify this script.
|
34 |
-
|
35 |
-
* `visualize_data.py`
|
36 |
-
|
37 |
-
Visualize ground truth raw annotations or training data (after preprocessing/augmentations).
|
38 |
-
|
39 |
-
Usage:
|
40 |
-
```
|
41 |
-
python visualize_data.py --config-file config.yaml --source annotation/dataloader --output-dir dir/ [--show]
|
42 |
-
```
|
43 |
-
|
44 |
-
NOTE: the script does not stop by itself when using `--source dataloader` because a training
|
45 |
-
dataloader is usually infinite.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CVPR/Text2Human/Text2Human/models/archs/shape_attr_embedding_arch.py
DELETED
@@ -1,35 +0,0 @@
|
|
1 |
-
import torch
|
2 |
-
import torch.nn.functional as F
|
3 |
-
from torch import nn
|
4 |
-
|
5 |
-
|
6 |
-
class ShapeAttrEmbedding(nn.Module):
|
7 |
-
|
8 |
-
def __init__(self, dim, out_dim, cls_num_list):
|
9 |
-
super(ShapeAttrEmbedding, self).__init__()
|
10 |
-
|
11 |
-
for idx, cls_num in enumerate(cls_num_list):
|
12 |
-
setattr(
|
13 |
-
self, f'attr_{idx}',
|
14 |
-
nn.Sequential(
|
15 |
-
nn.Linear(cls_num, dim), nn.LeakyReLU(),
|
16 |
-
nn.Linear(dim, dim)))
|
17 |
-
self.cls_num_list = cls_num_list
|
18 |
-
self.attr_num = len(cls_num_list)
|
19 |
-
self.fusion = nn.Sequential(
|
20 |
-
nn.Linear(dim * self.attr_num, out_dim), nn.LeakyReLU(),
|
21 |
-
nn.Linear(out_dim, out_dim))
|
22 |
-
|
23 |
-
def forward(self, attr):
|
24 |
-
attr_embedding_list = []
|
25 |
-
for idx in range(self.attr_num):
|
26 |
-
attr_embed_fc = getattr(self, f'attr_{idx}')
|
27 |
-
attr_embedding_list.append(
|
28 |
-
attr_embed_fc(
|
29 |
-
F.one_hot(
|
30 |
-
attr[:, idx],
|
31 |
-
num_classes=self.cls_num_list[idx]).to(torch.float32)))
|
32 |
-
attr_embedding = torch.cat(attr_embedding_list, dim=1)
|
33 |
-
attr_embedding = self.fusion(attr_embedding)
|
34 |
-
|
35 |
-
return attr_embedding
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CVPR/WALT/mmdet/models/roi_heads/mask_heads/feature_relay_head.py
DELETED
@@ -1,55 +0,0 @@
|
|
1 |
-
import torch.nn as nn
|
2 |
-
from mmcv.cnn import kaiming_init
|
3 |
-
from mmcv.runner import auto_fp16
|
4 |
-
|
5 |
-
from mmdet.models.builder import HEADS
|
6 |
-
|
7 |
-
|
8 |
-
@HEADS.register_module()
|
9 |
-
class FeatureRelayHead(nn.Module):
|
10 |
-
"""Feature Relay Head used in `SCNet <https://arxiv.org/abs/2012.10150>`_.
|
11 |
-
|
12 |
-
Args:
|
13 |
-
in_channels (int, optional): number of input channels. Default: 256.
|
14 |
-
conv_out_channels (int, optional): number of output channels before
|
15 |
-
classification layer. Default: 256.
|
16 |
-
roi_feat_size (int, optional): roi feat size at box head. Default: 7.
|
17 |
-
scale_factor (int, optional): scale factor to match roi feat size
|
18 |
-
at mask head. Default: 2.
|
19 |
-
"""
|
20 |
-
|
21 |
-
def __init__(self,
|
22 |
-
in_channels=1024,
|
23 |
-
out_conv_channels=256,
|
24 |
-
roi_feat_size=7,
|
25 |
-
scale_factor=2):
|
26 |
-
super(FeatureRelayHead, self).__init__()
|
27 |
-
assert isinstance(roi_feat_size, int)
|
28 |
-
|
29 |
-
self.in_channels = in_channels
|
30 |
-
self.out_conv_channels = out_conv_channels
|
31 |
-
self.roi_feat_size = roi_feat_size
|
32 |
-
self.out_channels = (roi_feat_size**2) * out_conv_channels
|
33 |
-
self.scale_factor = scale_factor
|
34 |
-
self.fp16_enabled = False
|
35 |
-
|
36 |
-
self.fc = nn.Linear(self.in_channels, self.out_channels)
|
37 |
-
self.upsample = nn.Upsample(
|
38 |
-
scale_factor=scale_factor, mode='bilinear', align_corners=True)
|
39 |
-
|
40 |
-
def init_weights(self):
|
41 |
-
"""Init weights for the head."""
|
42 |
-
kaiming_init(self.fc)
|
43 |
-
|
44 |
-
@auto_fp16()
|
45 |
-
def forward(self, x):
|
46 |
-
"""Forward function."""
|
47 |
-
N, in_C = x.shape
|
48 |
-
if N > 0:
|
49 |
-
out_C = self.out_conv_channels
|
50 |
-
out_HW = self.roi_feat_size
|
51 |
-
x = self.fc(x)
|
52 |
-
x = x.reshape(N, out_C, out_HW, out_HW)
|
53 |
-
x = self.upsample(x)
|
54 |
-
return x
|
55 |
-
return None
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CVPR/lama-example/bin/paper_runfiles/find_best_checkpoint.py
DELETED
@@ -1,54 +0,0 @@
|
|
1 |
-
#!/usr/bin/env python3
|
2 |
-
|
3 |
-
|
4 |
-
import os
|
5 |
-
from argparse import ArgumentParser
|
6 |
-
|
7 |
-
|
8 |
-
def ssim_fid100_f1(metrics, fid_scale=100):
|
9 |
-
ssim = metrics.loc['total', 'ssim']['mean']
|
10 |
-
fid = metrics.loc['total', 'fid']['mean']
|
11 |
-
fid_rel = max(0, fid_scale - fid) / fid_scale
|
12 |
-
f1 = 2 * ssim * fid_rel / (ssim + fid_rel + 1e-3)
|
13 |
-
return f1
|
14 |
-
|
15 |
-
|
16 |
-
def find_best_checkpoint(model_list, models_dir):
|
17 |
-
with open(model_list) as f:
|
18 |
-
models = [m.strip() for m in f.readlines()]
|
19 |
-
with open(f'{model_list}_best', 'w') as f:
|
20 |
-
for model in models:
|
21 |
-
print(model)
|
22 |
-
best_f1 = 0
|
23 |
-
best_epoch = 0
|
24 |
-
best_step = 0
|
25 |
-
with open(os.path.join(models_dir, model, 'train.log')) as fm:
|
26 |
-
lines = fm.readlines()
|
27 |
-
for line_index in range(len(lines)):
|
28 |
-
line = lines[line_index]
|
29 |
-
if 'Validation metrics after epoch' in line:
|
30 |
-
sharp_index = line.index('#')
|
31 |
-
cur_ep = line[sharp_index + 1:]
|
32 |
-
comma_index = cur_ep.index(',')
|
33 |
-
cur_ep = int(cur_ep[:comma_index])
|
34 |
-
total_index = line.index('total ')
|
35 |
-
step = int(line[total_index:].split()[1].strip())
|
36 |
-
total_line = lines[line_index + 5]
|
37 |
-
if not total_line.startswith('total'):
|
38 |
-
continue
|
39 |
-
words = total_line.strip().split()
|
40 |
-
f1 = float(words[-1])
|
41 |
-
print(f'\tEpoch: {cur_ep}, f1={f1}')
|
42 |
-
if f1 > best_f1:
|
43 |
-
best_f1 = f1
|
44 |
-
best_epoch = cur_ep
|
45 |
-
best_step = step
|
46 |
-
f.write(f'{model}\t{best_epoch}\t{best_step}\t{best_f1}\n')
|
47 |
-
|
48 |
-
|
49 |
-
if __name__ == '__main__':
|
50 |
-
parser = ArgumentParser()
|
51 |
-
parser.add_argument('model_list')
|
52 |
-
parser.add_argument('models_dir')
|
53 |
-
args = parser.parse_args()
|
54 |
-
find_best_checkpoint(args.model_list, args.models_dir)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CVPR/lama-example/fetch_data/sampler.py
DELETED
@@ -1,39 +0,0 @@
|
|
1 |
-
import os
|
2 |
-
import random
|
3 |
-
|
4 |
-
test_files_path = os.path.abspath('.') + '/places_standard_dataset/original/test/'
|
5 |
-
test_files = [test_files_path + image for image in os.listdir(test_files_path)]
|
6 |
-
print(f'found {len(test_files)} images in {test_files_path}')
|
7 |
-
|
8 |
-
random.shuffle(test_files)
|
9 |
-
test_files_random = test_files[0:2000]
|
10 |
-
#print(test_files_random[0:10])
|
11 |
-
|
12 |
-
list_of_random_test_files = os.path.abspath('.') \
|
13 |
-
+ '/places_standard_dataset/original/test_random_files.txt'
|
14 |
-
|
15 |
-
print(f'copying 100 random images to {list_of_random_test_files}')
|
16 |
-
with open(list_of_random_test_files, 'w') as fw:
|
17 |
-
for filename in test_files_random:
|
18 |
-
fw.write(filename+'\n')
|
19 |
-
print('...done')
|
20 |
-
|
21 |
-
# ----------------------------------------------------------------------------------
|
22 |
-
|
23 |
-
|
24 |
-
val_files_path = os.path.abspath('.') + '/places_standard_dataset/original/val/'
|
25 |
-
val_files = [val_files_path + image for image in os.listdir(val_files_path)]
|
26 |
-
print(f'found {len(val_files)} images in {val_files_path}')
|
27 |
-
|
28 |
-
random.shuffle(val_files)
|
29 |
-
val_files_random = val_files[0:100]
|
30 |
-
|
31 |
-
list_of_random_val_files = os.path.abspath('.') \
|
32 |
-
+ '/places_standard_dataset/original/val_random_files.txt'
|
33 |
-
|
34 |
-
print(f'copying 100 random images to {list_of_random_val_files}')
|
35 |
-
with open(list_of_random_val_files, 'w') as fw:
|
36 |
-
for filename in val_files_random:
|
37 |
-
fw.write(filename+'\n')
|
38 |
-
print('...done')
|
39 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/ChrisPreston/diff-svc_minato_aqua/utils/svc_utils.py
DELETED
@@ -1,141 +0,0 @@
|
|
1 |
-
import glob
|
2 |
-
import importlib
|
3 |
-
import os
|
4 |
-
|
5 |
-
import matplotlib
|
6 |
-
import numpy as np
|
7 |
-
import torch
|
8 |
-
import torch.distributions
|
9 |
-
import torch.optim
|
10 |
-
import torch.optim
|
11 |
-
import torch.utils.data
|
12 |
-
|
13 |
-
from preprocessing.process_pipeline import File2Batch
|
14 |
-
from utils.hparams import hparams
|
15 |
-
from utils.indexed_datasets import IndexedDataset
|
16 |
-
from utils.pitch_utils import norm_interp_f0
|
17 |
-
|
18 |
-
matplotlib.use('Agg')
|
19 |
-
|
20 |
-
|
21 |
-
class SvcDataset(torch.utils.data.Dataset):
|
22 |
-
def __init__(self, prefix, shuffle=False):
|
23 |
-
super().__init__()
|
24 |
-
self.hparams = hparams
|
25 |
-
self.shuffle = shuffle
|
26 |
-
self.sort_by_len = hparams['sort_by_len']
|
27 |
-
self.sizes = None
|
28 |
-
self.data_dir = hparams['binary_data_dir']
|
29 |
-
self.prefix = prefix
|
30 |
-
self.sizes = np.load(f'{self.data_dir}/{self.prefix}_lengths.npy')
|
31 |
-
self.indexed_ds = None
|
32 |
-
# self.name2spk_id={}
|
33 |
-
|
34 |
-
# pitch stats
|
35 |
-
f0_stats_fn = f'{self.data_dir}/train_f0s_mean_std.npy'
|
36 |
-
if os.path.exists(f0_stats_fn):
|
37 |
-
hparams['f0_mean'], hparams['f0_std'] = self.f0_mean, self.f0_std = np.load(f0_stats_fn)
|
38 |
-
hparams['f0_mean'] = float(hparams['f0_mean'])
|
39 |
-
hparams['f0_std'] = float(hparams['f0_std'])
|
40 |
-
else:
|
41 |
-
hparams['f0_mean'], hparams['f0_std'] = self.f0_mean, self.f0_std = None, None
|
42 |
-
|
43 |
-
if prefix == 'test':
|
44 |
-
if hparams['test_input_dir'] != '':
|
45 |
-
self.indexed_ds, self.sizes = self.load_test_inputs(hparams['test_input_dir'])
|
46 |
-
else:
|
47 |
-
if hparams['num_test_samples'] > 0:
|
48 |
-
self.avail_idxs = list(range(hparams['num_test_samples'])) + hparams['test_ids']
|
49 |
-
self.sizes = [self.sizes[i] for i in self.avail_idxs]
|
50 |
-
|
51 |
-
@property
|
52 |
-
def _sizes(self):
|
53 |
-
return self.sizes
|
54 |
-
|
55 |
-
def _get_item(self, index):
|
56 |
-
if hasattr(self, 'avail_idxs') and self.avail_idxs is not None:
|
57 |
-
index = self.avail_idxs[index]
|
58 |
-
if self.indexed_ds is None:
|
59 |
-
self.indexed_ds = IndexedDataset(f'{self.data_dir}/{self.prefix}')
|
60 |
-
return self.indexed_ds[index]
|
61 |
-
|
62 |
-
def __getitem__(self, index):
|
63 |
-
item = self._get_item(index)
|
64 |
-
max_frames = hparams['max_frames']
|
65 |
-
spec = torch.Tensor(item['mel'])[:max_frames]
|
66 |
-
# energy = (spec.exp() ** 2).sum(-1).sqrt()
|
67 |
-
mel2ph = torch.LongTensor(item['mel2ph'])[:max_frames] if 'mel2ph' in item else None
|
68 |
-
f0, uv = norm_interp_f0(item["f0"][:max_frames], hparams)
|
69 |
-
hubert = torch.Tensor(item['hubert'][:hparams['max_input_tokens']])
|
70 |
-
pitch = torch.LongTensor(item.get("pitch"))[:max_frames]
|
71 |
-
sample = {
|
72 |
-
"id": index,
|
73 |
-
"item_name": item['item_name'],
|
74 |
-
"hubert": hubert,
|
75 |
-
"mel": spec,
|
76 |
-
"pitch": pitch,
|
77 |
-
"f0": f0,
|
78 |
-
"uv": uv,
|
79 |
-
"mel2ph": mel2ph,
|
80 |
-
"mel_nonpadding": spec.abs().sum(-1) > 0,
|
81 |
-
}
|
82 |
-
if hparams['use_energy_embed']:
|
83 |
-
sample['energy'] = item['energy']
|
84 |
-
if hparams['use_spk_embed']:
|
85 |
-
sample["spk_embed"] = torch.Tensor(item['spk_embed'])
|
86 |
-
if hparams['use_spk_id']:
|
87 |
-
sample["spk_id"] = item['spk_id']
|
88 |
-
return sample
|
89 |
-
|
90 |
-
@staticmethod
|
91 |
-
def collater(samples):
|
92 |
-
return File2Batch.processed_input2batch(samples)
|
93 |
-
|
94 |
-
@staticmethod
|
95 |
-
def load_test_inputs(test_input_dir):
|
96 |
-
inp_wav_paths = glob.glob(f'{test_input_dir}/*.wav') + glob.glob(f'{test_input_dir}/*.mp3')
|
97 |
-
sizes = []
|
98 |
-
items = []
|
99 |
-
|
100 |
-
binarizer_cls = hparams.get("binarizer_cls", 'basics.base_binarizer.BaseBinarizer')
|
101 |
-
pkg = ".".join(binarizer_cls.split(".")[:-1])
|
102 |
-
cls_name = binarizer_cls.split(".")[-1]
|
103 |
-
binarizer_cls = getattr(importlib.import_module(pkg), cls_name)
|
104 |
-
from preprocessing.hubertinfer import HubertEncoder
|
105 |
-
for wav_fn in inp_wav_paths:
|
106 |
-
item_name = os.path.basename(wav_fn)
|
107 |
-
wav_fn = wav_fn
|
108 |
-
encoder = HubertEncoder(hparams['hubert_path'])
|
109 |
-
item = binarizer_cls.process_item(item_name, {'wav_fn': wav_fn}, encoder)
|
110 |
-
print(item)
|
111 |
-
items.append(item)
|
112 |
-
sizes.append(item['len'])
|
113 |
-
return items, sizes
|
114 |
-
|
115 |
-
def __len__(self):
|
116 |
-
return len(self._sizes)
|
117 |
-
|
118 |
-
def num_tokens(self, index):
|
119 |
-
return self.size(index)
|
120 |
-
|
121 |
-
def size(self, index):
|
122 |
-
"""Return an example's size as a float or tuple. This value is used when
|
123 |
-
filtering a dataset with ``--max-positions``."""
|
124 |
-
size = min(self._sizes[index], hparams['max_frames'])
|
125 |
-
return size
|
126 |
-
|
127 |
-
def ordered_indices(self):
|
128 |
-
"""Return an ordered list of indices. Batches will be constructed based
|
129 |
-
on this order."""
|
130 |
-
if self.shuffle:
|
131 |
-
indices = np.random.permutation(len(self))
|
132 |
-
if self.sort_by_len:
|
133 |
-
indices = indices[np.argsort(np.array(self._sizes)[indices], kind='mergesort')]
|
134 |
-
# 先random, 然后稳定排序, 保证排序后同长度的数据顺序是依照random permutation的 (被其随机打乱).
|
135 |
-
else:
|
136 |
-
indices = np.arange(len(self))
|
137 |
-
return indices
|
138 |
-
|
139 |
-
@property
|
140 |
-
def num_workers(self):
|
141 |
-
return int(os.getenv('NUM_WORKERS', hparams['ds_workers']))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/Cicooo/vits-uma-genshin-honkai/models.py
DELETED
@@ -1,534 +0,0 @@
|
|
1 |
-
import math
|
2 |
-
import torch
|
3 |
-
from torch import nn
|
4 |
-
from torch.nn import functional as F
|
5 |
-
|
6 |
-
import commons
|
7 |
-
import modules
|
8 |
-
import attentions
|
9 |
-
import monotonic_align
|
10 |
-
|
11 |
-
from torch.nn import Conv1d, ConvTranspose1d, Conv2d
|
12 |
-
from torch.nn.utils import weight_norm, remove_weight_norm, spectral_norm
|
13 |
-
from commons import init_weights, get_padding
|
14 |
-
|
15 |
-
|
16 |
-
class StochasticDurationPredictor(nn.Module):
|
17 |
-
def __init__(self, in_channels, filter_channels, kernel_size, p_dropout, n_flows=4, gin_channels=0):
|
18 |
-
super().__init__()
|
19 |
-
filter_channels = in_channels # it needs to be removed from future version.
|
20 |
-
self.in_channels = in_channels
|
21 |
-
self.filter_channels = filter_channels
|
22 |
-
self.kernel_size = kernel_size
|
23 |
-
self.p_dropout = p_dropout
|
24 |
-
self.n_flows = n_flows
|
25 |
-
self.gin_channels = gin_channels
|
26 |
-
|
27 |
-
self.log_flow = modules.Log()
|
28 |
-
self.flows = nn.ModuleList()
|
29 |
-
self.flows.append(modules.ElementwiseAffine(2))
|
30 |
-
for i in range(n_flows):
|
31 |
-
self.flows.append(modules.ConvFlow(2, filter_channels, kernel_size, n_layers=3))
|
32 |
-
self.flows.append(modules.Flip())
|
33 |
-
|
34 |
-
self.post_pre = nn.Conv1d(1, filter_channels, 1)
|
35 |
-
self.post_proj = nn.Conv1d(filter_channels, filter_channels, 1)
|
36 |
-
self.post_convs = modules.DDSConv(filter_channels, kernel_size, n_layers=3, p_dropout=p_dropout)
|
37 |
-
self.post_flows = nn.ModuleList()
|
38 |
-
self.post_flows.append(modules.ElementwiseAffine(2))
|
39 |
-
for i in range(4):
|
40 |
-
self.post_flows.append(modules.ConvFlow(2, filter_channels, kernel_size, n_layers=3))
|
41 |
-
self.post_flows.append(modules.Flip())
|
42 |
-
|
43 |
-
self.pre = nn.Conv1d(in_channels, filter_channels, 1)
|
44 |
-
self.proj = nn.Conv1d(filter_channels, filter_channels, 1)
|
45 |
-
self.convs = modules.DDSConv(filter_channels, kernel_size, n_layers=3, p_dropout=p_dropout)
|
46 |
-
if gin_channels != 0:
|
47 |
-
self.cond = nn.Conv1d(gin_channels, filter_channels, 1)
|
48 |
-
|
49 |
-
def forward(self, x, x_mask, w=None, g=None, reverse=False, noise_scale=1.0):
|
50 |
-
x = torch.detach(x)
|
51 |
-
x = self.pre(x)
|
52 |
-
if g is not None:
|
53 |
-
g = torch.detach(g)
|
54 |
-
x = x + self.cond(g)
|
55 |
-
x = self.convs(x, x_mask)
|
56 |
-
x = self.proj(x) * x_mask
|
57 |
-
|
58 |
-
if not reverse:
|
59 |
-
flows = self.flows
|
60 |
-
assert w is not None
|
61 |
-
|
62 |
-
logdet_tot_q = 0
|
63 |
-
h_w = self.post_pre(w)
|
64 |
-
h_w = self.post_convs(h_w, x_mask)
|
65 |
-
h_w = self.post_proj(h_w) * x_mask
|
66 |
-
e_q = torch.randn(w.size(0), 2, w.size(2)).to(device=x.device, dtype=x.dtype) * x_mask
|
67 |
-
z_q = e_q
|
68 |
-
for flow in self.post_flows:
|
69 |
-
z_q, logdet_q = flow(z_q, x_mask, g=(x + h_w))
|
70 |
-
logdet_tot_q += logdet_q
|
71 |
-
z_u, z1 = torch.split(z_q, [1, 1], 1)
|
72 |
-
u = torch.sigmoid(z_u) * x_mask
|
73 |
-
z0 = (w - u) * x_mask
|
74 |
-
logdet_tot_q += torch.sum((F.logsigmoid(z_u) + F.logsigmoid(-z_u)) * x_mask, [1,2])
|
75 |
-
logq = torch.sum(-0.5 * (math.log(2*math.pi) + (e_q**2)) * x_mask, [1,2]) - logdet_tot_q
|
76 |
-
|
77 |
-
logdet_tot = 0
|
78 |
-
z0, logdet = self.log_flow(z0, x_mask)
|
79 |
-
logdet_tot += logdet
|
80 |
-
z = torch.cat([z0, z1], 1)
|
81 |
-
for flow in flows:
|
82 |
-
z, logdet = flow(z, x_mask, g=x, reverse=reverse)
|
83 |
-
logdet_tot = logdet_tot + logdet
|
84 |
-
nll = torch.sum(0.5 * (math.log(2*math.pi) + (z**2)) * x_mask, [1,2]) - logdet_tot
|
85 |
-
return nll + logq # [b]
|
86 |
-
else:
|
87 |
-
flows = list(reversed(self.flows))
|
88 |
-
flows = flows[:-2] + [flows[-1]] # remove a useless vflow
|
89 |
-
z = torch.randn(x.size(0), 2, x.size(2)).to(device=x.device, dtype=x.dtype) * noise_scale
|
90 |
-
for flow in flows:
|
91 |
-
z = flow(z, x_mask, g=x, reverse=reverse)
|
92 |
-
z0, z1 = torch.split(z, [1, 1], 1)
|
93 |
-
logw = z0
|
94 |
-
return logw
|
95 |
-
|
96 |
-
|
97 |
-
class DurationPredictor(nn.Module):
|
98 |
-
def __init__(self, in_channels, filter_channels, kernel_size, p_dropout, gin_channels=0):
|
99 |
-
super().__init__()
|
100 |
-
|
101 |
-
self.in_channels = in_channels
|
102 |
-
self.filter_channels = filter_channels
|
103 |
-
self.kernel_size = kernel_size
|
104 |
-
self.p_dropout = p_dropout
|
105 |
-
self.gin_channels = gin_channels
|
106 |
-
|
107 |
-
self.drop = nn.Dropout(p_dropout)
|
108 |
-
self.conv_1 = nn.Conv1d(in_channels, filter_channels, kernel_size, padding=kernel_size//2)
|
109 |
-
self.norm_1 = modules.LayerNorm(filter_channels)
|
110 |
-
self.conv_2 = nn.Conv1d(filter_channels, filter_channels, kernel_size, padding=kernel_size//2)
|
111 |
-
self.norm_2 = modules.LayerNorm(filter_channels)
|
112 |
-
self.proj = nn.Conv1d(filter_channels, 1, 1)
|
113 |
-
|
114 |
-
if gin_channels != 0:
|
115 |
-
self.cond = nn.Conv1d(gin_channels, in_channels, 1)
|
116 |
-
|
117 |
-
def forward(self, x, x_mask, g=None):
|
118 |
-
x = torch.detach(x)
|
119 |
-
if g is not None:
|
120 |
-
g = torch.detach(g)
|
121 |
-
x = x + self.cond(g)
|
122 |
-
x = self.conv_1(x * x_mask)
|
123 |
-
x = torch.relu(x)
|
124 |
-
x = self.norm_1(x)
|
125 |
-
x = self.drop(x)
|
126 |
-
x = self.conv_2(x * x_mask)
|
127 |
-
x = torch.relu(x)
|
128 |
-
x = self.norm_2(x)
|
129 |
-
x = self.drop(x)
|
130 |
-
x = self.proj(x * x_mask)
|
131 |
-
return x * x_mask
|
132 |
-
|
133 |
-
|
134 |
-
class TextEncoder(nn.Module):
|
135 |
-
def __init__(self,
|
136 |
-
n_vocab,
|
137 |
-
out_channels,
|
138 |
-
hidden_channels,
|
139 |
-
filter_channels,
|
140 |
-
n_heads,
|
141 |
-
n_layers,
|
142 |
-
kernel_size,
|
143 |
-
p_dropout):
|
144 |
-
super().__init__()
|
145 |
-
self.n_vocab = n_vocab
|
146 |
-
self.out_channels = out_channels
|
147 |
-
self.hidden_channels = hidden_channels
|
148 |
-
self.filter_channels = filter_channels
|
149 |
-
self.n_heads = n_heads
|
150 |
-
self.n_layers = n_layers
|
151 |
-
self.kernel_size = kernel_size
|
152 |
-
self.p_dropout = p_dropout
|
153 |
-
|
154 |
-
self.emb = nn.Embedding(n_vocab, hidden_channels)
|
155 |
-
nn.init.normal_(self.emb.weight, 0.0, hidden_channels**-0.5)
|
156 |
-
|
157 |
-
self.encoder = attentions.Encoder(
|
158 |
-
hidden_channels,
|
159 |
-
filter_channels,
|
160 |
-
n_heads,
|
161 |
-
n_layers,
|
162 |
-
kernel_size,
|
163 |
-
p_dropout)
|
164 |
-
self.proj= nn.Conv1d(hidden_channels, out_channels * 2, 1)
|
165 |
-
|
166 |
-
def forward(self, x, x_lengths):
|
167 |
-
x = self.emb(x) * math.sqrt(self.hidden_channels) # [b, t, h]
|
168 |
-
x = torch.transpose(x, 1, -1) # [b, h, t]
|
169 |
-
x_mask = torch.unsqueeze(commons.sequence_mask(x_lengths, x.size(2)), 1).to(x.dtype)
|
170 |
-
|
171 |
-
x = self.encoder(x * x_mask, x_mask)
|
172 |
-
stats = self.proj(x) * x_mask
|
173 |
-
|
174 |
-
m, logs = torch.split(stats, self.out_channels, dim=1)
|
175 |
-
return x, m, logs, x_mask
|
176 |
-
|
177 |
-
|
178 |
-
class ResidualCouplingBlock(nn.Module):
|
179 |
-
def __init__(self,
|
180 |
-
channels,
|
181 |
-
hidden_channels,
|
182 |
-
kernel_size,
|
183 |
-
dilation_rate,
|
184 |
-
n_layers,
|
185 |
-
n_flows=4,
|
186 |
-
gin_channels=0):
|
187 |
-
super().__init__()
|
188 |
-
self.channels = channels
|
189 |
-
self.hidden_channels = hidden_channels
|
190 |
-
self.kernel_size = kernel_size
|
191 |
-
self.dilation_rate = dilation_rate
|
192 |
-
self.n_layers = n_layers
|
193 |
-
self.n_flows = n_flows
|
194 |
-
self.gin_channels = gin_channels
|
195 |
-
|
196 |
-
self.flows = nn.ModuleList()
|
197 |
-
for i in range(n_flows):
|
198 |
-
self.flows.append(modules.ResidualCouplingLayer(channels, hidden_channels, kernel_size, dilation_rate, n_layers, gin_channels=gin_channels, mean_only=True))
|
199 |
-
self.flows.append(modules.Flip())
|
200 |
-
|
201 |
-
def forward(self, x, x_mask, g=None, reverse=False):
|
202 |
-
if not reverse:
|
203 |
-
for flow in self.flows:
|
204 |
-
x, _ = flow(x, x_mask, g=g, reverse=reverse)
|
205 |
-
else:
|
206 |
-
for flow in reversed(self.flows):
|
207 |
-
x = flow(x, x_mask, g=g, reverse=reverse)
|
208 |
-
return x
|
209 |
-
|
210 |
-
|
211 |
-
class PosteriorEncoder(nn.Module):
|
212 |
-
def __init__(self,
|
213 |
-
in_channels,
|
214 |
-
out_channels,
|
215 |
-
hidden_channels,
|
216 |
-
kernel_size,
|
217 |
-
dilation_rate,
|
218 |
-
n_layers,
|
219 |
-
gin_channels=0):
|
220 |
-
super().__init__()
|
221 |
-
self.in_channels = in_channels
|
222 |
-
self.out_channels = out_channels
|
223 |
-
self.hidden_channels = hidden_channels
|
224 |
-
self.kernel_size = kernel_size
|
225 |
-
self.dilation_rate = dilation_rate
|
226 |
-
self.n_layers = n_layers
|
227 |
-
self.gin_channels = gin_channels
|
228 |
-
|
229 |
-
self.pre = nn.Conv1d(in_channels, hidden_channels, 1)
|
230 |
-
self.enc = modules.WN(hidden_channels, kernel_size, dilation_rate, n_layers, gin_channels=gin_channels)
|
231 |
-
self.proj = nn.Conv1d(hidden_channels, out_channels * 2, 1)
|
232 |
-
|
233 |
-
def forward(self, x, x_lengths, g=None):
|
234 |
-
x_mask = torch.unsqueeze(commons.sequence_mask(x_lengths, x.size(2)), 1).to(x.dtype)
|
235 |
-
x = self.pre(x) * x_mask
|
236 |
-
x = self.enc(x, x_mask, g=g)
|
237 |
-
stats = self.proj(x) * x_mask
|
238 |
-
m, logs = torch.split(stats, self.out_channels, dim=1)
|
239 |
-
z = (m + torch.randn_like(m) * torch.exp(logs)) * x_mask
|
240 |
-
return z, m, logs, x_mask
|
241 |
-
|
242 |
-
|
243 |
-
class Generator(torch.nn.Module):
|
244 |
-
def __init__(self, initial_channel, resblock, resblock_kernel_sizes, resblock_dilation_sizes, upsample_rates, upsample_initial_channel, upsample_kernel_sizes, gin_channels=0):
|
245 |
-
super(Generator, self).__init__()
|
246 |
-
self.num_kernels = len(resblock_kernel_sizes)
|
247 |
-
self.num_upsamples = len(upsample_rates)
|
248 |
-
self.conv_pre = Conv1d(initial_channel, upsample_initial_channel, 7, 1, padding=3)
|
249 |
-
resblock = modules.ResBlock1 if resblock == '1' else modules.ResBlock2
|
250 |
-
|
251 |
-
self.ups = nn.ModuleList()
|
252 |
-
for i, (u, k) in enumerate(zip(upsample_rates, upsample_kernel_sizes)):
|
253 |
-
self.ups.append(weight_norm(
|
254 |
-
ConvTranspose1d(upsample_initial_channel//(2**i), upsample_initial_channel//(2**(i+1)),
|
255 |
-
k, u, padding=(k-u)//2)))
|
256 |
-
|
257 |
-
self.resblocks = nn.ModuleList()
|
258 |
-
for i in range(len(self.ups)):
|
259 |
-
ch = upsample_initial_channel//(2**(i+1))
|
260 |
-
for j, (k, d) in enumerate(zip(resblock_kernel_sizes, resblock_dilation_sizes)):
|
261 |
-
self.resblocks.append(resblock(ch, k, d))
|
262 |
-
|
263 |
-
self.conv_post = Conv1d(ch, 1, 7, 1, padding=3, bias=False)
|
264 |
-
self.ups.apply(init_weights)
|
265 |
-
|
266 |
-
if gin_channels != 0:
|
267 |
-
self.cond = nn.Conv1d(gin_channels, upsample_initial_channel, 1)
|
268 |
-
|
269 |
-
def forward(self, x, g=None):
|
270 |
-
x = self.conv_pre(x)
|
271 |
-
if g is not None:
|
272 |
-
x = x + self.cond(g)
|
273 |
-
|
274 |
-
for i in range(self.num_upsamples):
|
275 |
-
x = F.leaky_relu(x, modules.LRELU_SLOPE)
|
276 |
-
x = self.ups[i](x)
|
277 |
-
xs = None
|
278 |
-
for j in range(self.num_kernels):
|
279 |
-
if xs is None:
|
280 |
-
xs = self.resblocks[i*self.num_kernels+j](x)
|
281 |
-
else:
|
282 |
-
xs += self.resblocks[i*self.num_kernels+j](x)
|
283 |
-
x = xs / self.num_kernels
|
284 |
-
x = F.leaky_relu(x)
|
285 |
-
x = self.conv_post(x)
|
286 |
-
x = torch.tanh(x)
|
287 |
-
|
288 |
-
return x
|
289 |
-
|
290 |
-
def remove_weight_norm(self):
|
291 |
-
print('Removing weight norm...')
|
292 |
-
for l in self.ups:
|
293 |
-
remove_weight_norm(l)
|
294 |
-
for l in self.resblocks:
|
295 |
-
l.remove_weight_norm()
|
296 |
-
|
297 |
-
|
298 |
-
class DiscriminatorP(torch.nn.Module):
|
299 |
-
def __init__(self, period, kernel_size=5, stride=3, use_spectral_norm=False):
|
300 |
-
super(DiscriminatorP, self).__init__()
|
301 |
-
self.period = period
|
302 |
-
self.use_spectral_norm = use_spectral_norm
|
303 |
-
norm_f = weight_norm if use_spectral_norm == False else spectral_norm
|
304 |
-
self.convs = nn.ModuleList([
|
305 |
-
norm_f(Conv2d(1, 32, (kernel_size, 1), (stride, 1), padding=(get_padding(kernel_size, 1), 0))),
|
306 |
-
norm_f(Conv2d(32, 128, (kernel_size, 1), (stride, 1), padding=(get_padding(kernel_size, 1), 0))),
|
307 |
-
norm_f(Conv2d(128, 512, (kernel_size, 1), (stride, 1), padding=(get_padding(kernel_size, 1), 0))),
|
308 |
-
norm_f(Conv2d(512, 1024, (kernel_size, 1), (stride, 1), padding=(get_padding(kernel_size, 1), 0))),
|
309 |
-
norm_f(Conv2d(1024, 1024, (kernel_size, 1), 1, padding=(get_padding(kernel_size, 1), 0))),
|
310 |
-
])
|
311 |
-
self.conv_post = norm_f(Conv2d(1024, 1, (3, 1), 1, padding=(1, 0)))
|
312 |
-
|
313 |
-
def forward(self, x):
|
314 |
-
fmap = []
|
315 |
-
|
316 |
-
# 1d to 2d
|
317 |
-
b, c, t = x.shape
|
318 |
-
if t % self.period != 0: # pad first
|
319 |
-
n_pad = self.period - (t % self.period)
|
320 |
-
x = F.pad(x, (0, n_pad), "reflect")
|
321 |
-
t = t + n_pad
|
322 |
-
x = x.view(b, c, t // self.period, self.period)
|
323 |
-
|
324 |
-
for l in self.convs:
|
325 |
-
x = l(x)
|
326 |
-
x = F.leaky_relu(x, modules.LRELU_SLOPE)
|
327 |
-
fmap.append(x)
|
328 |
-
x = self.conv_post(x)
|
329 |
-
fmap.append(x)
|
330 |
-
x = torch.flatten(x, 1, -1)
|
331 |
-
|
332 |
-
return x, fmap
|
333 |
-
|
334 |
-
|
335 |
-
class DiscriminatorS(torch.nn.Module):
|
336 |
-
def __init__(self, use_spectral_norm=False):
|
337 |
-
super(DiscriminatorS, self).__init__()
|
338 |
-
norm_f = weight_norm if use_spectral_norm == False else spectral_norm
|
339 |
-
self.convs = nn.ModuleList([
|
340 |
-
norm_f(Conv1d(1, 16, 15, 1, padding=7)),
|
341 |
-
norm_f(Conv1d(16, 64, 41, 4, groups=4, padding=20)),
|
342 |
-
norm_f(Conv1d(64, 256, 41, 4, groups=16, padding=20)),
|
343 |
-
norm_f(Conv1d(256, 1024, 41, 4, groups=64, padding=20)),
|
344 |
-
norm_f(Conv1d(1024, 1024, 41, 4, groups=256, padding=20)),
|
345 |
-
norm_f(Conv1d(1024, 1024, 5, 1, padding=2)),
|
346 |
-
])
|
347 |
-
self.conv_post = norm_f(Conv1d(1024, 1, 3, 1, padding=1))
|
348 |
-
|
349 |
-
def forward(self, x):
|
350 |
-
fmap = []
|
351 |
-
|
352 |
-
for l in self.convs:
|
353 |
-
x = l(x)
|
354 |
-
x = F.leaky_relu(x, modules.LRELU_SLOPE)
|
355 |
-
fmap.append(x)
|
356 |
-
x = self.conv_post(x)
|
357 |
-
fmap.append(x)
|
358 |
-
x = torch.flatten(x, 1, -1)
|
359 |
-
|
360 |
-
return x, fmap
|
361 |
-
|
362 |
-
|
363 |
-
class MultiPeriodDiscriminator(torch.nn.Module):
|
364 |
-
def __init__(self, use_spectral_norm=False):
|
365 |
-
super(MultiPeriodDiscriminator, self).__init__()
|
366 |
-
periods = [2,3,5,7,11]
|
367 |
-
|
368 |
-
discs = [DiscriminatorS(use_spectral_norm=use_spectral_norm)]
|
369 |
-
discs = discs + [DiscriminatorP(i, use_spectral_norm=use_spectral_norm) for i in periods]
|
370 |
-
self.discriminators = nn.ModuleList(discs)
|
371 |
-
|
372 |
-
def forward(self, y, y_hat):
|
373 |
-
y_d_rs = []
|
374 |
-
y_d_gs = []
|
375 |
-
fmap_rs = []
|
376 |
-
fmap_gs = []
|
377 |
-
for i, d in enumerate(self.discriminators):
|
378 |
-
y_d_r, fmap_r = d(y)
|
379 |
-
y_d_g, fmap_g = d(y_hat)
|
380 |
-
y_d_rs.append(y_d_r)
|
381 |
-
y_d_gs.append(y_d_g)
|
382 |
-
fmap_rs.append(fmap_r)
|
383 |
-
fmap_gs.append(fmap_g)
|
384 |
-
|
385 |
-
return y_d_rs, y_d_gs, fmap_rs, fmap_gs
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
class SynthesizerTrn(nn.Module):
|
390 |
-
"""
|
391 |
-
Synthesizer for Training
|
392 |
-
"""
|
393 |
-
|
394 |
-
def __init__(self,
|
395 |
-
n_vocab,
|
396 |
-
spec_channels,
|
397 |
-
segment_size,
|
398 |
-
inter_channels,
|
399 |
-
hidden_channels,
|
400 |
-
filter_channels,
|
401 |
-
n_heads,
|
402 |
-
n_layers,
|
403 |
-
kernel_size,
|
404 |
-
p_dropout,
|
405 |
-
resblock,
|
406 |
-
resblock_kernel_sizes,
|
407 |
-
resblock_dilation_sizes,
|
408 |
-
upsample_rates,
|
409 |
-
upsample_initial_channel,
|
410 |
-
upsample_kernel_sizes,
|
411 |
-
n_speakers=0,
|
412 |
-
gin_channels=0,
|
413 |
-
use_sdp=True,
|
414 |
-
**kwargs):
|
415 |
-
|
416 |
-
super().__init__()
|
417 |
-
self.n_vocab = n_vocab
|
418 |
-
self.spec_channels = spec_channels
|
419 |
-
self.inter_channels = inter_channels
|
420 |
-
self.hidden_channels = hidden_channels
|
421 |
-
self.filter_channels = filter_channels
|
422 |
-
self.n_heads = n_heads
|
423 |
-
self.n_layers = n_layers
|
424 |
-
self.kernel_size = kernel_size
|
425 |
-
self.p_dropout = p_dropout
|
426 |
-
self.resblock = resblock
|
427 |
-
self.resblock_kernel_sizes = resblock_kernel_sizes
|
428 |
-
self.resblock_dilation_sizes = resblock_dilation_sizes
|
429 |
-
self.upsample_rates = upsample_rates
|
430 |
-
self.upsample_initial_channel = upsample_initial_channel
|
431 |
-
self.upsample_kernel_sizes = upsample_kernel_sizes
|
432 |
-
self.segment_size = segment_size
|
433 |
-
self.n_speakers = n_speakers
|
434 |
-
self.gin_channels = gin_channels
|
435 |
-
|
436 |
-
self.use_sdp = use_sdp
|
437 |
-
|
438 |
-
self.enc_p = TextEncoder(n_vocab,
|
439 |
-
inter_channels,
|
440 |
-
hidden_channels,
|
441 |
-
filter_channels,
|
442 |
-
n_heads,
|
443 |
-
n_layers,
|
444 |
-
kernel_size,
|
445 |
-
p_dropout)
|
446 |
-
self.dec = Generator(inter_channels, resblock, resblock_kernel_sizes, resblock_dilation_sizes, upsample_rates, upsample_initial_channel, upsample_kernel_sizes, gin_channels=gin_channels)
|
447 |
-
self.enc_q = PosteriorEncoder(spec_channels, inter_channels, hidden_channels, 5, 1, 16, gin_channels=gin_channels)
|
448 |
-
self.flow = ResidualCouplingBlock(inter_channels, hidden_channels, 5, 1, 4, gin_channels=gin_channels)
|
449 |
-
|
450 |
-
if use_sdp:
|
451 |
-
self.dp = StochasticDurationPredictor(hidden_channels, 192, 3, 0.5, 4, gin_channels=gin_channels)
|
452 |
-
else:
|
453 |
-
self.dp = DurationPredictor(hidden_channels, 256, 3, 0.5, gin_channels=gin_channels)
|
454 |
-
|
455 |
-
if n_speakers > 1:
|
456 |
-
self.emb_g = nn.Embedding(n_speakers, gin_channels)
|
457 |
-
|
458 |
-
def forward(self, x, x_lengths, y, y_lengths, sid=None):
|
459 |
-
|
460 |
-
x, m_p, logs_p, x_mask = self.enc_p(x, x_lengths)
|
461 |
-
if self.n_speakers > 0:
|
462 |
-
g = self.emb_g(sid).unsqueeze(-1) # [b, h, 1]
|
463 |
-
else:
|
464 |
-
g = None
|
465 |
-
|
466 |
-
z, m_q, logs_q, y_mask = self.enc_q(y, y_lengths, g=g)
|
467 |
-
z_p = self.flow(z, y_mask, g=g)
|
468 |
-
|
469 |
-
with torch.no_grad():
|
470 |
-
# negative cross-entropy
|
471 |
-
s_p_sq_r = torch.exp(-2 * logs_p) # [b, d, t]
|
472 |
-
neg_cent1 = torch.sum(-0.5 * math.log(2 * math.pi) - logs_p, [1], keepdim=True) # [b, 1, t_s]
|
473 |
-
neg_cent2 = torch.matmul(-0.5 * (z_p ** 2).transpose(1, 2), s_p_sq_r) # [b, t_t, d] x [b, d, t_s] = [b, t_t, t_s]
|
474 |
-
neg_cent3 = torch.matmul(z_p.transpose(1, 2), (m_p * s_p_sq_r)) # [b, t_t, d] x [b, d, t_s] = [b, t_t, t_s]
|
475 |
-
neg_cent4 = torch.sum(-0.5 * (m_p ** 2) * s_p_sq_r, [1], keepdim=True) # [b, 1, t_s]
|
476 |
-
neg_cent = neg_cent1 + neg_cent2 + neg_cent3 + neg_cent4
|
477 |
-
|
478 |
-
attn_mask = torch.unsqueeze(x_mask, 2) * torch.unsqueeze(y_mask, -1)
|
479 |
-
attn = monotonic_align.maximum_path(neg_cent, attn_mask.squeeze(1)).unsqueeze(1).detach()
|
480 |
-
|
481 |
-
w = attn.sum(2)
|
482 |
-
if self.use_sdp:
|
483 |
-
l_length = self.dp(x, x_mask, w, g=g)
|
484 |
-
l_length = l_length / torch.sum(x_mask)
|
485 |
-
else:
|
486 |
-
logw_ = torch.log(w + 1e-6) * x_mask
|
487 |
-
logw = self.dp(x, x_mask, g=g)
|
488 |
-
l_length = torch.sum((logw - logw_)**2, [1,2]) / torch.sum(x_mask) # for averaging
|
489 |
-
|
490 |
-
# expand prior
|
491 |
-
m_p = torch.matmul(attn.squeeze(1), m_p.transpose(1, 2)).transpose(1, 2)
|
492 |
-
logs_p = torch.matmul(attn.squeeze(1), logs_p.transpose(1, 2)).transpose(1, 2)
|
493 |
-
|
494 |
-
z_slice, ids_slice = commons.rand_slice_segments(z, y_lengths, self.segment_size)
|
495 |
-
o = self.dec(z_slice, g=g)
|
496 |
-
return o, l_length, attn, ids_slice, x_mask, y_mask, (z, z_p, m_p, logs_p, m_q, logs_q)
|
497 |
-
|
498 |
-
def infer(self, x, x_lengths, sid=None, noise_scale=1, length_scale=1, noise_scale_w=1., max_len=None):
|
499 |
-
device = next(self.parameters()).device # 获取模型所在的设备
|
500 |
-
x, m_p, logs_p, x_mask = self.enc_p(x.to(device), x_lengths.to(device))
|
501 |
-
if self.n_speakers > 0:
|
502 |
-
g = self.emb_g(sid.to(device)).unsqueeze(-1) # [b, h, 1]
|
503 |
-
else:
|
504 |
-
g = None
|
505 |
-
|
506 |
-
if self.use_sdp:
|
507 |
-
logw = self.dp(x, x_mask, g=g, reverse=True, noise_scale=noise_scale_w)
|
508 |
-
else:
|
509 |
-
logw = self.dp(x, x_mask, g=g)
|
510 |
-
w = torch.exp(logw) * x_mask * length_scale
|
511 |
-
w_ceil = torch.ceil(w)
|
512 |
-
y_lengths = torch.clamp_min(torch.sum(w_ceil, [1, 2]), 1).long()
|
513 |
-
y_mask = torch.unsqueeze(commons.sequence_mask(y_lengths, None), 1).to(x_mask.dtype)
|
514 |
-
attn_mask = torch.unsqueeze(x_mask, 2) * torch.unsqueeze(y_mask, -1)
|
515 |
-
attn = commons.generate_path(w_ceil, attn_mask)
|
516 |
-
|
517 |
-
m_p = torch.matmul(attn.squeeze(1), m_p.transpose(1, 2)).transpose(1, 2) # [b, t', t], [b, t, d] -> [b, d, t']
|
518 |
-
logs_p = torch.matmul(attn.squeeze(1), logs_p.transpose(1, 2)).transpose(1, 2) # [b, t', t], [b, t, d] -> [b, d, t']
|
519 |
-
|
520 |
-
z_p = m_p + torch.randn_like(m_p) * torch.exp(logs_p) * noise_scale
|
521 |
-
z = self.flow(z_p, y_mask, g=g, reverse=True)
|
522 |
-
o = self.dec((z * y_mask)[:,:,:max_len], g=g)
|
523 |
-
return o, attn, y_mask, (z, z_p, m_p, logs_p)
|
524 |
-
|
525 |
-
def voice_conversion(self, y, y_lengths, sid_src, sid_tgt):
|
526 |
-
assert self.n_speakers > 0, "n_speakers have to be larger than 0."
|
527 |
-
g_src = self.emb_g(sid_src).unsqueeze(-1)
|
528 |
-
g_tgt = self.emb_g(sid_tgt).unsqueeze(-1)
|
529 |
-
z, m_q, logs_q, y_mask = self.enc_q(y, y_lengths, g=g_src)
|
530 |
-
z_p = self.flow(z, y_mask, g=g_src)
|
531 |
-
z_hat = self.flow(z_p, y_mask, g=g_tgt, reverse=True)
|
532 |
-
o_hat = self.dec(z_hat * y_mask, g=g_tgt)
|
533 |
-
return o_hat, y_mask, (z, z_p, z_hat)
|
534 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
spaces/CofAI/chat/server/website.py
DELETED
@@ -1,58 +0,0 @@
|
|
1 |
-
from flask import render_template, redirect, url_for, request, session
|
2 |
-
from flask_babel import refresh
|
3 |
-
from time import time
|
4 |
-
from os import urandom
|
5 |
-
from server.babel import get_locale, get_languages
|
6 |
-
|
7 |
-
|
8 |
-
class Website:
|
9 |
-
def __init__(self, bp, url_prefix) -> None:
|
10 |
-
self.bp = bp
|
11 |
-
self.url_prefix = url_prefix
|
12 |
-
self.routes = {
|
13 |
-
'/': {
|
14 |
-
'function': lambda: redirect(url_for('._index')),
|
15 |
-
'methods': ['GET', 'POST']
|
16 |
-
},
|
17 |
-
'/chat/': {
|
18 |
-
'function': self._index,
|
19 |
-
'methods': ['GET', 'POST']
|
20 |
-
},
|
21 |
-
'/chat/<conversation_id>': {
|
22 |
-
'function': self._chat,
|
23 |
-
'methods': ['GET', 'POST']
|
24 |
-
},
|
25 |
-
'/change-language': {
|
26 |
-
'function': self.change_language,
|
27 |
-
'methods': ['POST']
|
28 |
-
},
|
29 |
-
'/get-locale': {
|
30 |
-
'function': self.get_locale,
|
31 |
-
'methods': ['GET']
|
32 |
-
},
|
33 |
-
'/get-languages': {
|
34 |
-
'function': self.get_languages,
|
35 |
-
'methods': ['GET']
|
36 |
-
}
|
37 |
-
}
|
38 |
-
|
39 |
-
def _chat(self, conversation_id):
|
40 |
-
if '-' not in conversation_id:
|
41 |
-
return redirect(url_for('._index'))
|
42 |
-
|
43 |
-
return render_template('index.html', chat_id=conversation_id, url_prefix=self.url_prefix)
|
44 |
-
|
45 |
-
def _index(self):
|
46 |
-
return render_template('index.html', chat_id=f'{urandom(4).hex()}-{urandom(2).hex()}-{urandom(2).hex()}-{urandom(2).hex()}-{hex(int(time() * 1000))[2:]}', url_prefix=self.url_prefix)
|
47 |
-
|
48 |
-
def change_language(self):
|
49 |
-
data = request.get_json()
|
50 |
-
session['language'] = data.get('language')
|
51 |
-
refresh()
|
52 |
-
return '', 204
|
53 |
-
|
54 |
-
def get_locale(self):
|
55 |
-
return get_locale()
|
56 |
-
|
57 |
-
def get_languages(self):
|
58 |
-
return get_languages()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|