Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a module which can iterate the workdir and find the target files … #2047

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

ForkCarpenter
Copy link

…without duplicates,a method different from cim2pp.ipynb in tutorials.

…without duplicates,a method different from cim2pp.ipynb in tutorials.
@@ -1,21 +1,71 @@
# import os
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like this commented code can be removed

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well,since this change is not so necessary , I prefer keep this "commented code" to keep up with the tutorial of "cim2pp.ipynb" , this code is more experimental rather than the original cods. and its's just tested with vscode in linux now, I didn't test it in NT system. By the way, I had tried to use the relative path, the "/" in posix and "" in nt is frustrated, that is another reason I turn to the iterable function. I'd like to comment here like that:" this fucntion is a optional method, the commented code above is more easy and simple for guys focus on prime concept. " , could this be done?

@rbolgaryn
Copy link
Member

Dear @ForkCarpenter ,

can you please explain in the comments what the new function is doing? It is not very easy to understand how the function works exactly.

Also, please modify the CHANGELOG.rst file.

Best regards,
Roman

@ForkCarpenter
Copy link
Author

can you please explain in the comments what the new function is doing? It is not very easy to understand how the function works exactly.

Dear Sir @rbolgaryn :
This is not a fix in necessity,but for guys who wanna debug the CIM RDF files they created themselves or data copied from other source like "Villasframework", this function would be useful. And in addition changes in this issue have fixed 2 Negligible bugs while running the tutorial of "cim2pp.ipynb". First to run "folder_path = os.path.join(os.getcwd(), 'example_cim')" successfully, current work_dir for python console must 'CD' to "pandapower/tutorial" first , that is to say to make the absolute path working fine,both in the "testfiles/example_cim" dir and "turitorial/example_cim" dir should be stored with the example cgmes zip files. Well,hereby code automation is better choice, with this function , all we need is just "CD" to the "pandapower/" dir ,in other words ,the parent dir, and no matter where the zip files is and how many places they are stored in, the tutorial code can work well. the only cost is time in pytest last for 10 more seconds :P.

The second subtle bug is at the end of plotting , the picture doesn't show on automatically ,the "matplotlib.pyplot" show() function seems necessary .

The other reason I keep working on this change is that in the future front-end programming like pyQT styled interactive dialog box. it's more useful for the Iterable "find_files" function as I thiink.

And sorry for that I'm totally amateur on programming, your latest issue in pytest was a good example for me, thank you very much, I'd like to comment in more details on the code to make it understood More easily , include the CHANGELOG.rst file.

Best wishes
Wilson

ForkCarpenter added a commit to ForkCarpenter/pandapower that referenced this pull request May 20, 2023
@heckstrahler
Copy link
Contributor

heckstrahler commented Mar 27, 2024

Dear @ForkCarpenter,

We had looked at your request.

A few points:

  • In general, we have nothing against your alternative method for determining the input files for the converter. However, we do not understand why it is needed in the first place. Could you explain in more detail why you need this functionality and what its benefits are?

  • The test of plotting functionality has no place in the converter test.

  • Do not put comments at the top of the test file. This includes the out commented code lines. Additionally, we do not know what you are trying to show us with this comment.

  • Since file io is not part of the converter code your tests are in our opinion not in the right place. The test_from_cim.py file should only contain tests that directly test the converter functionality.

  • We are not sure what you mean by module since you only added a method.

Please elaborate more on these points and move your test from test_from_cim to another file, otherwise we must decline your pull request.
Kind regards.

@KS-HTK KS-HTK added question Further information is requested labels May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants