It looks like you are trying to use this code on a WordPress page, rather than a post.
I would expect you to have created parent-child relationships with Types between two different post types (e.g. projects -> tasks ), and then add code on the template for the single child posts use code to retrieve the id of the parent post to be used as you will.
But the link you shared appears to be a static WordPress page and so I guess it is not a Types child of another post and hence there is no parent id to retrieve.
That will create a debug.log file in your wp-content directory which you can examine in any text editor.
Now add a line in your code to print the parent id you have retrieved to the log to confirm that the expected parent id has been returned by the function:
error_log("parent id is " . $parent_assump_post_id);