Skip to content

Simplified folder Structure #132

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

Closed
wants to merge 2 commits into from
Closed

Conversation

kolibril13
Copy link
Member

In regard of #66 this pull request removes the nested folder stucture in the output.
Tested with:

from manim import *

class Test(Scene):
    def construct(self):
        dot = Dot()
        self.add(dot)
        self.wait(1)
        self.play(Transform(dot, Circle()))
        self.wait()

from pathlib import Path
if __name__ == "__main__":
    script = f"{Path(__file__).resolve()}"
    os.system(f"manim  -l -p -c 'BLACK' --video_dir ~/Downloads/ " + script )

When the argument --video_dir ~/Downloads/ " is defined.

"images",
module_directory,
))
if self.save_last_frame:
Copy link
Contributor

Choose a reason for hiding this comment

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

We still need to check for self.save_pngs here, no?

Copy link
Member Author

Choose a reason for hiding this comment

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

oh, you are right!

Comment on lines +80 to +82
movie_dir = guarantee_existence(os.path.join(
dirs.VIDEO_DIR
))
Copy link
Contributor

Choose a reason for hiding this comment

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

It is my understanding from #66 that we are still going to have subdirectories for different resolutions. CC @eulertour

Copy link
Member Author

Choose a reason for hiding this comment

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

In my opinion subdirectories for different resolutions are not that beneficial, because with them it is not anymore easy to switch between videos when working with the explorer.
Further, it is very easy to obtain the video result on very quickly: right-click on the file, and then on "show information", or you can get a feeling of the resolution when looking on the size the video file has. Also, any video-editing software is showing the clip resolution.
So I would definitely prefer the simpler version, where videos are easy to access.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I wouldn't prefer being forced to run with the simple structure. Making it optional would be okay, forcing it on everyone, not so much.

@PgBiel PgBiel requested a review from eulertour June 3, 2020 14:34
added self.save_pngs
@PgBiel PgBiel added pr:deprecation Deprecation, or removal of deprecated code enhancement Additions and improvements in general labels Jun 3, 2020
Copy link
Collaborator

@XorUnison XorUnison left a comment

Choose a reason for hiding this comment

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

I'm against enforcing a simple folder structure on anyone as I prefer having them sorted by resolution. Furthermore dropping the folder structure and not even adding it to the name means that different resolutions overwrite one another.

@kolibril13
Copy link
Member Author

Different resolutions overwriting each other is for me a convenient feature because I normally don't need the low-resolution video anymore when I have the high-resolution one. But that might be personal taste, and I am in to make the simple folder structure an option.
Two ideas:

  1. The option -b, --basic for a basic (simple) folder structure and the subfolder is default
  2. The option -rd, --resolutiondir for optional resolution subfolders and simple folder structure as default.

@eulertour
Copy link
Member

This would make for a good addition to the config file after #98 is merged.

@leotrs
Copy link
Contributor

leotrs commented Jun 7, 2020

In my opinion subdirectories for different resolutions are not that beneficial
Different resolutions overwriting each other is for me a convenient feature because I normally don't need the low-resolution video anymore when I have the high-resolution one

The way we are trying to do things here is by first reaching a consensus with at least a few of the core devs before implementing anything. As per the lengthy discussion over at #66, we had already agreed to a particular structure. In the future, I would appreciate it if you searched the issues for ongoing (or past/closed) discussion before submitting a PR that would change the consensus.

because with them it is not anymore easy to switch between videos when working with the explorer.
Further, it is very easy to obtain the video result on very quickly: right-click on the file, and then on "show information", or you can get a feeling of the resolution when looking on the size the video file has. Also, any video-editing software is showing the clip resolution.

I personally do not use any of (i) "the explorer", (ii) the mouse/pointer (so I can't right click - in fact I don't even know what you mean by "show information"... is this system dependent?), or (iii) video editing software, and, further, (iv) I do not know how to tell the resolution by looking at the file size. We should try to develop manim with as wide an audience as possible.

So I would definitely prefer the simpler version, where videos are easy to access.

As you can see in #66, I personally agree with this statement, but there are other very strong arguments to not have your suggested folder structure the default.

But that might be personal taste, and I am in to make the simple folder structure an option.

I think this is the best way to go here. Once more, as you can see here, it had been already proposed to do this optionally through the future .cfg file.

I say all of this with the best intentions possible, and mainly because I see a lot of duplicated discussion/work here that has already occurred elsewhere.

@leotrs
Copy link
Contributor

leotrs commented Jun 7, 2020

As it stands, it seems to me that this PR currently does not actually follow the discussion that has been carried out in #66 (unless I'm missing something?). To implement something like this optionally, we should probably do that after #98 is merged. I vote we close this until that point.

@PgBiel
Copy link
Member

PgBiel commented Jun 10, 2020

probably should make a new PR after #98 is merged in order to not have to deal with merge conflict stuff

@Aathish04 Aathish04 changed the title #Simplified folder Structure Simplified folder Structure Jul 10, 2020
@leotrs
Copy link
Contributor

leotrs commented Jul 10, 2020

@kolibril13 now that #98 has been merged, if you are still willing, please implement this simplified folder structure as optional, and by making use of the new config system. I'm closing this one.

@leotrs leotrs closed this Jul 10, 2020
@kolibril13 kolibril13 deleted the new_scene_file_writer branch August 15, 2020 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Additions and improvements in general pr:deprecation Deprecation, or removal of deprecated code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants