human
get file basename without extension.
assistant
Here is a Python function to get file basename without extension

import os

def get_basename(filename):
    """Get the basename of a file."""
    return os.path.basename(filename)

# Enter the filename
filename = '/home/rosey/Desktop/test.txt'

# Calling the function
print((get_basename(filename)))

#Example Output
# test.txt

#Remember to inspect code for bugs.