Code Monkey home page Code Monkey logo

Comments (8)

lewiuberg avatar lewiuberg commented on June 2, 2024 2

Great! My first actual assignment :) I'll do it right after some pressing tasks. Have a good night!

from pycm.

sepandhaghighi avatar sepandhaghighi commented on June 2, 2024 1

Good point!
We will work on it in a future release.
@sadrasabouri

from pycm.

lewiuberg avatar lewiuberg commented on June 2, 2024 1

Great!

If you like I can give it a go later this week :)

from pycm.

sadrasabouri avatar sadrasabouri commented on June 2, 2024 1

Great!

If you like I can give it a go later this week :)

Yes that would be totally good. So I'm assigning you to it.
Feel free and thanks for your efforts. 💯

from pycm.

sepandhaghighi avatar sepandhaghighi commented on June 2, 2024 1

Great! My first actual assignment :) I'll do it right after some pressing tasks. Have a good night!

Very well! 🥇
Before starting please take a look at our Contributing guidelines

from pycm.

sadrasabouri avatar sadrasabouri commented on June 2, 2024 1

Hi! Some really pressing issues came in. I have not forgotten, but I had to postpone all other tasks for a while. Sorry:)

No problem. Take your time. There is no rush.

from pycm.

lewiuberg avatar lewiuberg commented on June 2, 2024

Here is my temporary solution for my particular problem.

def replace_text_in_file(file_path, text_to_replace, replacement_text):
    with open(file_path, "r") as f:
        content = f.read()
    new_content = content.replace(text_to_replace, replacement_text)
    with open(file_path, "w") as f:
        f.write(new_content)


def remove_sort_from_pycm_classes():
    import os
    import site

    from pycm import ConfusionMatrix

    SITE_PACKAGES_PATH = site.getsitepackages()
    PYCM_PATH = os.path.join(SITE_PACKAGES_PATH[0], "pycm")
    PYCM_OBJ_FILE = os.path.join(PYCM_PATH, "pycm_obj.py")
    print(PYCM_OBJ_FILE)

    replace_text_in_file(
        PYCM_OBJ_FILE,
        "self.classes = sorted(list(mapping.values()))",
        "self.classes = list(mapping.values())",
    )


remove_sort_from_pycm_classes()

from pycm.

lewiuberg avatar lewiuberg commented on June 2, 2024

Hi! Some really pressing issues came in. I have not forgotten, but I had to postpone all other tasks for a while. Sorry:)

from pycm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.