refactoring descriptors computation [NOT Working]