midjourney-api icon indicating copy to clipboard operation
midjourney-api copied to clipboard

当调用量大了之后,100张,会需要人工验证。

Open ddkwing opened this issue 2 years ago • 11 comments
trafficstars

请问该如何解决这个情况

ddkwing avatar May 22 '23 12:05 ddkwing

我现在还没遇上这种情况,能提供截图吗

yokonsan avatar May 22 '23 12:05 yokonsan

239658260-42c1bc02-8174-4ca2-9433-e551a52d7e88

ddkwing avatar May 23 '23 03:05 ddkwing

感谢 这似乎只能上报错误提示,由业务端处理了

yokonsan avatar May 23 '23 05:05 yokonsan

请问: 一直提示这个错误:iscord.errors.PrivilegedIntentsRequired: Shard ID None is requesting privileged intents that have not been explicitly enabled in the developer portal. It is recommended to go to the privileged intents within your application's page. If this is not possible, then consider disabling the privileged intents instead 这是什么情况?

getidone avatar May 26 '23 03:05 getidone

请问: 一直提示这个错误:iscord.errors.PrivilegedIntentsRequired: Shard ID None is requesting privileged intents that have not been explicitly enabled in the developer portal. It is recommended to go to the privileged intents within your application's page. If this is not possible, then consider disabling the privileged intents instead 这是什么情况?

解决了

getidone avatar May 26 '23 05:05 getidone

我做了一个验证码解析器,这是代码: https://file.io/IbISKKXxVcxu

你需要运行"setup.bat"或"setup.sh",然后可以查看"example.py",解析器的演示在那里。

randomsnippets avatar Jun 05 '23 18:06 randomsnippets

我做了一个验证码解析器,这是代码: https://file.io/IbISKKXxVcxu

你需要运行"setup.bat"或"setup.sh",然后可以查看"example.py",解析器的演示在那里。

看不到是不是链接异常了

skrleo avatar Jun 07 '23 03:06 skrleo

出2000多张了,还没遇上验证码 😂

yokonsan avatar Jun 07 '23 09:06 yokonsan

出2000多张了,还没遇上验证码 😂

Captcha solver:

from spacy import load
from imageai.Classification import ImageClassification

class CaptchaSolver:
    def __init__(self, imageai_model: str):
        self.__nlpm = load("en_core_web_lg")
        self.__imageai_model = imageai_model

    def __describe_image(self, image_path: str):
        prediction = ImageClassification()

        prediction.setModelTypeAsResNet50()
        prediction.setModelPath(self.__imageai_model)
        prediction.loadModel()

        results = prediction.classifyImage(image_path)

        return {label: score for label, score in zip(results[0], results[1])}

    def __compare_word_to_list(self, input_word: str, word_list: list):
        similar_words = {}

        for current_word in word_list:
            similarity_score = self.__nlpm(input_word).similarity(self.__nlpm(current_word))
            similar_words[current_word] = similarity_score

        return max(similar_words.values())

    def solve(self, captcha_answers: list, image_path: str):
        best_fit = None
        best_similarity = 0
        image_classification = self.__describe_image(image_path)

        for answer in captcha_answers:
            similarity = self.__compare_word_to_list(answer, list(image_classification.keys()))

            if similarity > best_similarity:
                best_fit = answer
                best_similarity = similarity

        return best_fit

requirements:

pip install spacy imageai
python -m spacy download en_core_web_lg
curl -o ./resnet50.pth https://github.com/OlafenwaMoses/ImageAI/releases/download/3.0.0-pretrained/resnet50-19c8e357.pth

randomsnippets avatar Jul 08 '23 20:07 randomsnippets

image 关掉这个应该就可以了。

Sandralan-calmdown avatar Aug 04 '23 03:08 Sandralan-calmdown

请问: 一直提示这个错误:iscord.errors.PrivilegedIntentsRequired: Shard ID None is requesting privileged intents that have not been explicitly enabled in the developer portal. It is recommended to go to the privileged intents within your application's page. If this is not possible, then consider disabling the privileged intents instead 这是什么情况?

解决了

我也遇到了相同问题,请问是如何解决的

Kinbon avatar Sep 04 '24 09:09 Kinbon