Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Should neural_network/gan.py_tf be rehabilitated or rewritten? #8937

tianyizheng02 started this conversation in General
Discussion options

Re: @cclauss's comment on #8936:

Please add an issue to rehabilitate neural_network/gan.py_tf

While working on #8936, I noticed these issues with neural_network/gan.py_tf:

  • As I pointed out in Fix ruff errors #8936 , the code relies on a separate file, neural_network/input_data.py.DEPRECATED.txt, to get the train/validation/test data. As the filename suggests, the file is deprecated, and neural_network/gan.py_tf shouldn't need to rely on this deprecated code. I believe the file was taken directly from TensorFlow's codebase, and comments in the file already state the recommended way to get the required data.

  • If we take a look at the current code, we'll see that the bulk of the implementation is contained in a massive __main__ block. All of this should be refactored into functions for readability and ease of testing.

  • I think the code was plagiarized. The file itself contains a comment referencing this Medium article, which is only available to Medium members. From what I was able to see, however, it appears that the implementation was directly copied (with the same variable names and comments).

With these issues in mind, how should we address this file? Should it be merely rehabilitated (meaning that we re-enable the file with minimal changes), or should it be heavily refactored or even completely rewritten?

You must be logged in to vote

Replies: 1 comment

Comment options

To decide whether to merely rehabilitate or to heavily refactor (as you put it) we should first investigate the plagiarism allegations. Personally I think some refactoring is way overdue to make the code easier to read.

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /