triggering python scripts

Discussions related to creating NIM project structures
Post Reply
keyframe
Posts: 4
Joined: March 30th, 2016, 6:43 pm

triggering python scripts

Post by keyframe »

Heya everyone,

We are in the process of bringing NIM online in a growing VFX deptartment -- We are all very excited to centralize all of our information in one place.

I do have a few questions that I haven't been able to find answers to in the docs:

(1) How can I trigger a python script that runs after a project is brought online? (We create a few pipeline related files that set app versions, and manage path envars, control the renderfarm, etc)
(2) Is it possible to use the '.' as a delimiter between the <job_number> and the <job_name>? (I also enjoy being able to create .pipeline folders, which are hidden by linux convention)
(3) I would love to be able to make a visual distinction between an <asset_name> and a <show_name> -- since they live at the same level in the project structure (as I believe they should). It doesn't need to be anything more robust then being able to append a string to <asset_name>. Is this possible?

[edit]
(4) Is it possible to run without a <show_name> level? I feel that the project/sequence/shot layers might be overkill for some of our smaller projects.
(5) I'd like to embed some metadata about the template which was used to create the project (imagine a commercial template/mograph template/feature template) somewhere on disk in order to help linux navigation shortcut aliases. possible?
[/edit]

Best,

G

User avatar
andrew
Site Admin
Posts: 337
Joined: June 24th, 2014, 8:10 am

Re: triggering python scripts

Post by andrew »

Hi,

1) Triggered events are something we are looking to integrate in a future build as it has been a highly requested feature.

2) Currently the '.' results in an invalid character popup in our Project Structures but we will change that to allow '.''s in folder names.

3) You can append any string you want to the exiting variables and they will be respected when the folder is created. ie. 'ASSET_<asset_name>'

4) It is not possible to run without the show root level as we allow for shots across shows to have the same shot name.

5) I think this would likely be achieved using the triggered events to add whatever metadata you like to disk. Any of the root paths for a given job are also accessible through the API if that helps you generate aliases.

Thanks,
Andrew

keyframe
Posts: 4
Joined: March 30th, 2016, 6:43 pm

Re: triggering python scripts

Post by keyframe »

Thanks for the feedback Andrew,

Much appreciated. I assume that you can't comment on ETA for the triggered events... ;)
... it would solve many small issues that we are attempting to deal with (setting user/group permissions, working around naming, metadata, etc).

re: (3), It doesn't seem that i'm able to modify the <asset_name> field. Running version 1.0.2.151112. (see attached nim_asset_name.png). I can obviously ask users to append _ASSET to the asset name, but that feels a tad optimistic for my liking ;P

I've also attempted to merge <show_name>_<asset_name>, following the third option in the dialog (see attached nim_merge_show_asset.png), but was unable to do so. bug? I also tried to create a new field called <show_name>_<asset_name> based on that dialog, without success.

Another question came up. Is it possible to have a project structure span multiple NFS volumes? We have some directories staged on high IOPS storage for renderfarm reasons, while other directories are sitting on NAS to accomodate online, and DI workflows.
Attachments
nim_merge_show_asset.png
nim_merge_show_asset.png (17.96 KiB) Viewed 1507 times
nim_asset_name.png
nim_asset_name.png (78.17 KiB) Viewed 1507 times

User avatar
andrew
Site Admin
Posts: 337
Joined: June 24th, 2014, 8:10 am

Re: triggering python scripts

Post by andrew »

Hi,

I can't say too much for an exact ETA but it is on the immediate roadmap.

You are correct about modifying root fields. I spoke a little too soon. In there version you are running that was not an editable field, however in this was incorporated into our beta and will be a feature that is released shortly. If you are currently on support, email a request to sales@nim-labs.com to be included in the beta and you will have full access to any beta updates for the latest in new features.

As for multiple NFS volumes, when you bring a project online you can have multiple project servers for a single job. The project folders will be replicated across all servers and when using the NIM connectors direct your project files to one server and then direct your renders to another.

Thanks,
Andrew

keyframe
Posts: 4
Joined: March 30th, 2016, 6:43 pm

Re: triggering python scripts

Post by keyframe »

Heya Andrew,

Apologies for resurrecting an old thread. Just wanted to check in during a production lull to find out whether there has been any updates on this front.
Specifically, i'm looking for the ability to trigger pipeline-level python scripts via NIM.
Cheers,

G

User avatar
andrew
Site Admin
Posts: 337
Joined: June 24th, 2014, 8:10 am

Re: triggering python scripts

Post by andrew »

Hi,

(1) How can I trigger a python script that runs after a project is brought online? (We create a few pipeline related files that set app versions, and manage path envars, control the renderfarm, etc)

We are in the process of adding triggered events which will allow you to do this exact thing.


(2) Is it possible to use the '.' as a delimiter between the <job_number> and the <job_name>? (I also enjoy being able to create .pipeline folders, which are hidden by linux convention)

Yes, you can modify your Project Structure template to define this naming structure. However after checking on this I see there is a bug when you only have variables and periods it sees the name as invalid. This was in an effort to restrict creating folders named . or .. but NIM should be recognizing the fact that there are variables included which make it valid. We just fixed this and it will be updated in the next release. That being said adding a .pipeline folder to your Project Structure should work find for you.

(3) I would love to be able to make a visual distinction between an <asset_name> and a <show_name> -- since they live at the same level in the project structure (as I believe they should). It doesn't need to be anything more robust then being able to append a string to <asset_name>. Is this possible?

Definitely. Just go into the Admin/Project Structure page and update those entries to include whatever string you like. For instance you could change the asset root folder name to A_<asset_name> to prefix all of your assets with an A_ if you wish.

(4) Is it possible to run without a <show_name> level? I feel that the project/sequence/shot layers might be overkill for some of our smaller projects.

Unfortunately we don't have a work around here. A show is required to group your shots under.

(5) I'd like to embed some metadata about the template which was used to create the project (imagine a commercial template/mograph template/feature template) somewhere on disk in order to help linux navigation shortcut aliases. possible?

This would be achievable using the triggered events system once that is in place. We also have added a way to override the default script that creates folders so you will be able to add custom code that could write to a template as folders are made.

Cheers,
Andrew

Post Reply