Use numpy structured array instead of dict to save space and keep speed
numpy array use contiguous block of memory and can store only one type of object like int, float, string or other object. Where each item are allocated fixed bytes in memory. 
Numpy also provide set of functions for operation like traversing array, arithmetic operation, some string operation on those stored items which are implemented using c. As these operation doesn't have overhead of python they are normally more efficient in terms of both memory and processing power
As you need key value pair you can also store that in numpy array similar to c-struct but it won't have features like dict like looking of item, checking if key existing filtering etc. you have do do those your self using array functionality
better option for you may be pandas series, which also use numpy array to store its data for provides you lots of functionality on top of it
Are numpy structured arrays an alternative to Python dict?
I would like to save memory and I cannot affort much of a performance decline.
In my case, the keys are str and the values are int.
Can you give a quick conversion line in case they actually are an alternative?
I also don't mind if you can suggest a different alternative.
I need to save memory, because some dictionaries get larger than 50Gb in memory and I need to open multiple at a time with 'only' 192 GB RAM available.