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

Registration #8

Merged
merged 54 commits into from
Mar 10, 2018
Merged

Registration #8

merged 54 commits into from
Mar 10, 2018

Commits on Feb 2, 2018

  1. Configuration menu
    Copy the full SHA
    9780d96 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7f0490e View commit details
    Browse the repository at this point in the history

Commits on Feb 3, 2018

  1. More work on hand and all over.

    Simplified API calls and removed a lot of logging
    Added untested AbstractGrouping.insert_transform_buffer as a way to insert a buffer node from the context of a Grouping.
    Made the API property a true dictionary and allowed for APIs to be accessible along with the new APIProxy.DEFAULT_API property.
    
    Added fileop function to dcc.scene.
    Completely removed digit as it makes more sense to add as a method than a class.
    Added test suite for Hand but haven't filled it in.
    AndresMWeber committed Feb 3, 2018
    Configuration menu
    Copy the full SHA
    ab6b6f0 View commit details
    Browse the repository at this point in the history

Commits on Feb 6, 2018

  1. More work on hands.

    Added layout joints to the Hand rig and changed from the weirdly added kwarg finger_joints which was unnecessary.
    
    Worked more on get_finger_base_names as that function wasn't great so current functionality is there with a test suite.
    AndresMWeber committed Feb 6, 2018
    Configuration menu
    Copy the full SHA
    f9414de View commit details
    Browse the repository at this point in the history

Commits on Feb 7, 2018

  1. Reworked the build_ik and build_fk methods and moved them all to SubR…

    …igTemplate rather than SubRig and also shifted over build_ik from Hierarchy as that is not the responsibility of Hierarchy.
    
    Added methods:
    Transform.get_children - gets children of the DagNode.
    SubRigTemplate.get_shape_list - fills out a list of shapes to match a length of joint chains.
    AndresMWeber committed Feb 7, 2018
    Configuration menu
    Copy the full SHA
    c3e4def View commit details
    Browse the repository at this point in the history
  2. Added a new .ma file for the skeleton hand.

    Fixed the file import for the test hand file.
    AndresMWeber committed Feb 7, 2018
    Configuration menu
    Copy the full SHA
    d649229 View commit details
    Browse the repository at this point in the history
  3. Added a new .ma file for the skeleton hand.

    Fixed the file import for the test hand file.
    AndresMWeber committed Feb 7, 2018
    Configuration menu
    Copy the full SHA
    c208ec3 View commit details
    Browse the repository at this point in the history

Commits on Feb 8, 2018

  1. Fixed parenting in AbstractGrouping to work with the built in parent …

    …method instead of going direct to the dcc.
    
    Made the error in Hierarchy._traverse_up_linear_tree more verbose for node filter.
    
    Fixed build_blend_chain so it uses a duplicate flag and is more standardized.
    
    Combined the two IK/FK chain results into one dict.
    
    Added anvil.utils.scene.print_scene_tree.
    
    Fixed up the implementation of TestBuildHand as errors in the Hand build process would error the entire test class which would screw up the tests.  So now worked it in as a setUp instead.  Also added the Hand test properties to the Base class.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    aa1e556 View commit details
    Browse the repository at this point in the history
  2. Forgot to add the parent constraint to the FK chain joints.

    Removed the fbx file.
    Changed back to the class method.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    f01b131 View commit details
    Browse the repository at this point in the history
  3. Removed the is_built check until we need that functionality. For now …

    …assuming full build from the start.
    
    Added specific layout_joints kwarg popping so we can init from a serialized dict.
    Added default shape dict in BipedFoot for easy control shape lookups
    Changed the build order to reflect the proper foot control hierarchy
    Added a BipedFoot.build_ik_toe so that we can do a traditional reverse ik via the has_ik property.
    Also added an init kwarg/property so we can define the leg_ik in order to parent that to the correct control.
    Honestly it might make more sense to subclass a leg class so we don't build two foot controls.
    Refactored the test names and removed the word build as it was redundant.
    
    Set up a persistent rig foot build TestCase to reduce rig recreation.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    48f238a View commit details
    Browse the repository at this point in the history
  4. Removed setattr override for MetaData as I can't work out a good way …

    …to sensibly make it work. Will continue overwriting name_tokens via dict item assignment.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    49c9278 View commit details
    Browse the repository at this point in the history
  5. Added Transform.duplicate so I don't have to access the DCC all the t…

    …ime directly!
    
    Added MULT_DIV_TYPE to config.
    Took the Ankle control build out of the build for loop...unnecessary and complicates things.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    942c976 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    0c96a14 View commit details
    Browse the repository at this point in the history
  7. Fixed build_ik...the start joint was actually never being respected f…

    …rom the start if you don't set the flag...
    
    Fixed the duplicate condition for Foot building and hopefully fixed the build_ik_toe chain builds.
    
    Removed the toeEnd joint so retargetted all the test builds to the toe.
    
    Added a foot with leg test skeleton file to test integration with a preexisting leg setup.
    AndresMWeber committed Feb 8, 2018
    Configuration menu
    Copy the full SHA
    9751758 View commit details
    Browse the repository at this point in the history

Commits on Feb 9, 2018

  1. Configuration menu
    Copy the full SHA
    c7d77e8 View commit details
    Browse the repository at this point in the history
  2. Reworked HierarchyChain.insert_buffer quite a bit as it was not funct…

    …ioning.
    
    Removed a few log calls that were unnecessary.
    Changed to import from for anvil functions to simplify calls.
    Added Transform.reset_transform for ease.
    Simplified unnecessary match_rotation/match_position
    Starting to add functionality for BipedFoot.insert_pivot_buffer (insole/outside)
    Completely changed TestBuildBipedFoot so we can run pre/post hooks on the build process, this helps run the test case where we have to create a leg IK to "merge" it to a preexisting leg rig.
    AndresMWeber committed Feb 9, 2018
    Configuration menu
    Copy the full SHA
    ddbae84 View commit details
    Browse the repository at this point in the history

Commits on Feb 10, 2018

  1. Fixed node registration a bit more so it properly cast the dag_node t…

    …o anvil object.
    
    Worked a bit more on buffer inserts...added logic for replacing the head.
    Realized I swapped the collocation logic, need to fix the insert...currently it is not adding the children of the insert target to the new buffer.
    Added back the anvil namespace to the module functions as it was causing a circular import.
    
    Mapped anvil.factory to most of the node query functions on Transform.
    
    on BipedFoot cast all inputs to anvil.factory and built out insert_pivot_buffer a bunch.
    Added test case for bipedFoot + insole/outsole and added files to boot.
    AndresMWeber committed Feb 10, 2018
    Configuration menu
    Copy the full SHA
    d09198b View commit details
    Browse the repository at this point in the history

Commits on Feb 16, 2018

  1. Changed insert_buffer's kwarg from collocate to beneath for easier un…

    …derstanding.
    
    Fixed the behavior of insert_buffer as well, however it might not be matching transform still, checking this out.
    
    Added DagNode.delete that uses the dcc to delete the node reference.
    Removed a log line from match_transform
    
    Added custom errors and fixed the RuntimeError catching from APIProxy to be more verbose.
    
    Added insole/outsole input to the test so we can properly test for it.
    AndresMWeber committed Feb 16, 2018
    Configuration menu
    Copy the full SHA
    2b65295 View commit details
    Browse the repository at this point in the history
  2. Refactored insert_buffer to insert_and_build_buffer to be more specific.

    Added insert_node which is a more abstract form, this will allow for easier insertions.
    AndresMWeber committed Feb 16, 2018
    Configuration menu
    Copy the full SHA
    33fc7fc View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3081fac View commit details
    Browse the repository at this point in the history
  4. Fixing the tests

    AndresMWeber committed Feb 16, 2018
    Configuration menu
    Copy the full SHA
    3617f0c View commit details
    Browse the repository at this point in the history

Commits on Feb 17, 2018

  1. Removed the new inserted node from the get_children call since we can…

    …'t parent the inserted node to itself!
    
    In transform added initialization kwargs t, r, s since I realized I only had reference_object in there...
    
    Added all new tests for the insertion functions of HierarchyChain.
    AndresMWeber committed Feb 17, 2018
    Configuration menu
    Copy the full SHA
    c692c84 View commit details
    Browse the repository at this point in the history
  2. Added .landscape.yml

    Fixed a ton of code smell from landscape.io check:
    https://landscape.io/github/AndresMWeber/Anvil/102/
    AndresMWeber committed Feb 17, 2018
    Configuration menu
    Copy the full SHA
    1ff7014 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    86a9e66 View commit details
    Browse the repository at this point in the history
  4. Removed error checking in register from sub rig on Rig as we should e…

    …rror if someone inputs a bad sub_rig_dict.
    
    Fixed init to match the base class for BipedFoot as it was causing mis-fires on init from dict.
    
    Fixed the naming issue on the test skeleton files (classic mirroring misnames ball->balr and heel->heer)
    AndresMWeber committed Feb 17, 2018
    Configuration menu
    Copy the full SHA
    9f15bce View commit details
    Browse the repository at this point in the history
  5. removed mistaken print.

    AndresMWeber committed Feb 17, 2018
    Configuration menu
    Copy the full SHA
    ca2597e View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    71ae3e1 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    e197551 View commit details
    Browse the repository at this point in the history

Commits on Feb 18, 2018

  1. Configuration menu
    Copy the full SHA
    86dc287 View commit details
    Browse the repository at this point in the history

Commits on Feb 19, 2018

  1. Refactored traversal to relationships as it has more to do with node …

    …relationships now.
    
    Added class NodeRelation for the base class of relationship sets:
    HierarchyChain (linearly parented node chain)
    NonLinearSet(Non directly parented set of nodes that has a respected order.)
    
    Added AbstractGrouping.generate_build_report to standardize build report dicts.
    Added bunch to the requirements for easy dot notation access to the hierarchy.
    Added AbstractGrouping.register_build_nodes to automatically consume a build_report and add to the AbstractGrouping().hierarchy.
    
    Started to rework SubRigTemplate/BipedFoot's build methods to work with the new registration paradigms.
    Removed MetaData.cls_merge_name_tokens_and_meta_data as it wasn't used anymore and also added a protect_all flag to automatically protect all initialized kwargs if the user wants.
    AndresMWeber committed Feb 19, 2018
    Configuration menu
    Copy the full SHA
    5446978 View commit details
    Browse the repository at this point in the history

Commits on Feb 21, 2018

  1. Refactored traversal to relationships as it has more to do with node …

    …relationships now.
    
    Added class NodeRelation for the base class of relationship sets:
    HierarchyChain (linearly parented node chain)
    NonLinearSet(Non directly parented set of nodes that has a respected order.)
    
    Added AbstractGrouping.generate_build_report to standardize build report dicts.
    Added bunch to the requirements for easy dot notation access to the hierarchy.
    Added AbstractGrouping.register_build_nodes to automatically consume a build_report and add to the AbstractGrouping().hierarchy.
    
    Started to rework SubRigTemplate/BipedFoot's build methods to work with the new registration paradigms.
    Removed MetaData.cls_merge_name_tokens_and_meta_data as it wasn't used anymore and also added a protect_all flag to automatically protect all initialized kwargs if the user wants.
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    1d8e150 View commit details
    Browse the repository at this point in the history
  2. Started reworking the HierarchyChain and relationships.py classes in …

    …general
    
    Refactored the names of the classes to be more demonstrative.
    
    Trying to refactor all simple functions to the base class and simplify the classes in general.
    
    Added simple pre/post scene sanitization wrapper based on cleanup_nodes.  Might just build this into the test runner of the base class so I don't have to keep tagging.
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    14533ee View commit details
    Browse the repository at this point in the history
  3. All tests are passing, continuing with registration logic.

    Overrode the set property to LinearHierarchySet._traverse_up_linear_tree so it worked and fixed the __getitem__ function.
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    d480e45 View commit details
    Browse the repository at this point in the history
  4. Added insert and add_buffer from the foot branch.

    Pushed self.nodes assignment to base class NodeRelationshipSet.
    Added abstract methods extend, append and insert.
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    4b6c4e4 View commit details
    Browse the repository at this point in the history
  5. Removed Bunch implementation as it was failing due to displaying data…

    … errors during printing/yaml load/dumping.
    
    Converted generate_build_report to a wrapper.  This will usually be chained with register_built_nodes.
    Removed insert_transform_buffer as it was a duplicate from NonLinearHierarchySet.
    
    Starting to change the logic behind Control as it is acting a bit non sensically as it currently stands.
    
    Modifying the main build process to match the new registration process.  Need to find a better plan than getting the last node created in the nodes list.
    
    Refactored test_hierarchy_chain to test_relationships and added new tests for registration in test_abstract_grouping.
    
    Fixed the wrapping functionality for pre_and_post_sanitize_scene with @functools.wraps.
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    def4e0e View commit details
    Browse the repository at this point in the history
  6. Merge remote-tracking branch 'origin/dev-biped' into fix-registration

    # Conflicts:
    #	anvil/grouping/__init__.py
    #	anvil/grouping/base.py
    #	anvil/grouping/relationships.py
    #	anvil/grouping/rig.py
    #	anvil/meta_data.py
    #	anvil/sub_rig_templates/base.py
    #	anvil/sub_rig_templates/biped_foot.py
    #	tests/acceptance/test_biped.py
    #	tests/test_relationships.py
    AndresMWeber committed Feb 21, 2018
    Configuration menu
    Copy the full SHA
    10b4be5 View commit details
    Browse the repository at this point in the history

Commits on Feb 22, 2018

  1. Added Control._fix_child_name_tokens until I get the build/__init__ c…

    …ontracts more sorted out in my head for this outlying class.
    
    Simplified the get_tag lambda function and added REPORT_LOOKUP to easily sort incoming object types.
    Might simplify the report as needing to access a dictionary key is a bit silly currently, but that's how it's implemented in Rig.
    Added config.SET_TYPE
    Removed bunch from requirements and added nose-exclude.
    Refactored TestBase.delete_created_scene to TestBase.clean_up_scene and improved the wrapper implementation
    AndresMWeber committed Feb 22, 2018
    Configuration menu
    Copy the full SHA
    d8ef4ee View commit details
    Browse the repository at this point in the history

Commits on Feb 23, 2018

  1. Slowly converting to the new hierarchy dot notation.

    Added generic.Map class which is a dot notation accessible subclass of dict.
    Added generic.to_size_list to be able to match a list to a specific size (padding to right with [-1] index if needed.
    Fixed up registration to use new Map class.
    
    Added more documentation to generate_build_report.
    Added AbstractGrouping.register_node to register already built nodes.
    
    Added SET_TYPE, ANVIL_TYPE, and ID_TYPE
    Vastly simplified the wrappers for sanitizing test scenes.
    AndresMWeber committed Feb 23, 2018
    Configuration menu
    Copy the full SHA
    6394143 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    52142ac View commit details
    Browse the repository at this point in the history
  3. Added anvil.utils.generic.gen_flatten_dict_depth_two for quickly flat…

    …tening the hierarchy Map instance.
    
    Added anvil.grouping.AbstractGrouping._flatten_hierarchy() to follow up.
    
    Fixed Control implementation and simplified build steps to be more legible.
    Modified all build methods to classmethods, however this is breaking the SubRigTemplate builds as it is passing as a class and not an instance.  Need to figure this one out next.
    
    Removed SubRigTemplate.get_shape_list since it was redundant to to_size_list which is much better and generalized.
    
    Added MetaData.to_dict to stop pissing off kwargs linting.
    
    Modified so many tests to get in line with new hierarchy registration.
    AndresMWeber committed Feb 23, 2018
    Configuration menu
    Copy the full SHA
    286fb3a View commit details
    Browse the repository at this point in the history
  4. More fitting into new registration methodology.

    Converted all build functions back to instance methods.  class methods proved unnecessary for now.
    Refactored anvil.sub_rig_templates.base to base_sub_rig_templates.
    
    Moved SubRigTemplate.get_shape_list tests to test against to_size_list in generic as well as added a test file for generic.
    AndresMWeber committed Feb 23, 2018
    Configuration menu
    Copy the full SHA
    361664e View commit details
    Browse the repository at this point in the history
  5. Fixing errors based on CircleCI build 224

    https://circleci.com/gh/AndresMWeber/Anvil/224
    
    Minor mistakes like not pulling out the name tokens from kwargs when redefining or adding to.
    Forgot to use _flat_hierarchy to pull all controls out easily to the top level for testing against.
    Forgot to change dot notation access to the result dict to getitem access as it is raw and not yet a mapping.
    Changed property implementation of NodeSet.ANVIL_TYPE
    AndresMWeber committed Feb 23, 2018
    Configuration menu
    Copy the full SHA
    1befe4f View commit details
    Browse the repository at this point in the history

Commits on Feb 24, 2018

  1. Fixing the build calls so that the created objects get parented in Hand.

    Refactored/moved all test resources to anvil/tests/resources.
    AndresMWeber committed Feb 24, 2018
    Configuration menu
    Copy the full SHA
    75c449c View commit details
    Browse the repository at this point in the history

Commits on Feb 25, 2018

  1. Modified the _cascading_function to permit for the new hierarchy arra…

    …ngement.
    
    Removed NodeHierarchySet.rename as it was pointless.
    Reworked how the build functionality works in sub_rig_template.
    Added is_aset to permit for the new Anvil base class.
    AndresMWeber committed Feb 25, 2018
    Configuration menu
    Copy the full SHA
    5d88c1f View commit details
    Browse the repository at this point in the history
  2. Added skip_register flag to skip registration if we are doing a chain…

    …ed build call (so things get sorted properly to the hierarchy).
    
    Removed is_class since it actually did not work.
    
    Added testing to see if we are within CIRCLECI.
    Simplified safe_delete.
    Refactored cleanup_nodes to sanitize for brevity.
    
    Removed a ton of functions from BaseTest as they are not in use anymore.
    
    Added dict_deep_sort to convert a dictionary of dictionaries to a sorted nest of OrderedDict
    
    Moved sanitize_scene to utils.scene.
    AndresMWeber committed Feb 25, 2018
    Configuration menu
    Copy the full SHA
    3c01e4b View commit details
    Browse the repository at this point in the history
  3. Removed skip_register from signature as that was causing mistakes in …

    …the function wrap. Added a kwargs.get to detect instead.
    
    Safe delete has been turned into a catchall exception since I couldn't account effectively for MayaNodeError that pymel throws and assuming there would be other platform specific errors I don't want to account for.
    
    Converted most iteritems that threw out the keys to itervalues as I just realized that existed...
    AndresMWeber committed Feb 25, 2018
    Configuration menu
    Copy the full SHA
    2974d26 View commit details
    Browse the repository at this point in the history
  4. Added #noqa to the __init__ of objects/groupings to ignore custom __a…

    …ll__ and non-use.
    
    Fixed a bunch of code smell and warnings from https://landscape.io/github/AndresMWeber/Anvil/122
    
    Starting to implement using skip_register.  Seeing how this performs in base_sub_rig_template and limb
    Removed most logging calls.
    AndresMWeber committed Feb 25, 2018
    Configuration menu
    Copy the full SHA
    8abec3c View commit details
    Browse the repository at this point in the history
  5. Realized I needed to intercept skip_register from the kwargs and pop …

    …or else it would pass on to the decorated function as well.
    AndresMWeber committed Feb 25, 2018
    Configuration menu
    Copy the full SHA
    0c3b964 View commit details
    Browse the repository at this point in the history

Commits on Feb 26, 2018

  1. Added skip_report as well and ironinig out the implementation to figu…

    …re out when to pop the flags properly.
    
    Blend chain is erroring, not sure why yet.
    AndresMWeber committed Feb 26, 2018
    Configuration menu
    Copy the full SHA
    2cd3b8e View commit details
    Browse the repository at this point in the history

Commits on Mar 5, 2018

  1. Moved registration to registration.py at the top level.

    Fixed repr for base class NodeSet
    
    Fixed documentation for build_blend_chain to reflect limitations of Maya blendColors node.
    Fixed implementation for build_blend_chain as the zipping was not working properly based on the simplified inputs from the build fk/ik functions
    Fixed the way Limb passed fk/ik chains to build_blend_chain.
    Added Choice node to config.
    AndresMWeber committed Mar 5, 2018
    Configuration menu
    Copy the full SHA
    9b3dfe3 View commit details
    Browse the repository at this point in the history
  2. Fixed manual_id kwarg to be recognized by generate_report in register…

    …_node.
    
    Mid-fixing registration of nodes in the Hand rig build process.
    
    Turned the flag detection into pop to avoid pushing kwargs etc in registration functions.
    AndresMWeber committed Mar 5, 2018
    Configuration menu
    Copy the full SHA
    191184a View commit details
    Browse the repository at this point in the history

Commits on Mar 9, 2018

  1. Added __repr__ for relationships classes.

    Added hierarchy_id flag for registration.
    AndresMWeber committed Mar 9, 2018
    Configuration menu
    Copy the full SHA
    43a30ed View commit details
    Browse the repository at this point in the history
  2. Added auto_save_result wrapper to save results from test cases to che…

    …ck the files in Maya so I don't have to restart Maya every time.
    AndresMWeber committed Mar 9, 2018
    Configuration menu
    Copy the full SHA
    bc0650c View commit details
    Browse the repository at this point in the history

Commits on Mar 10, 2018

  1. Fixed parenting for controls and added an override_root kwarg so we c…

    …an not rely on instance.root being set and can use arbitrary "top" nodes to parent a rig
    
    Fixed the auto_save_results so that we are now properly saving out files that represent the state of the test case.  This will make testing MUCH easier and quicker.
    
    Changed auto_save_results to read environment variables instead so that we can set env vars instead of rely on passing kwargs which is less easy to do with unittests.
    AndresMWeber committed Mar 10, 2018
    Configuration menu
    Copy the full SHA
    62c1a09 View commit details
    Browse the repository at this point in the history