<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 Using the two contig names you sent me it's simplest to do this
Step1:  If you have a genuinely big file then I would do the following
Step2:  Ya! There's two contigs.
<ASSISTANT_TASK:>
Python Code:
desired_contigs = ['Contig' + str(x) for x in [1131, 3182, 39106, 110, 5958]]
desired_contigs
Explanation: Using the two contig names you sent me it's simplest to do this:
End of explanation
grab = [c for c in contigs if c.name in desired_contigs]
len(grab)
Explanation: If you have a genuinely big file then I would do the following:
End of explanation
import os
print(os.getcwd())
write_contigs_to_file('data2/sequences_desired.fa', grab)
[c.name for c in grab[:100]]
import os
os.path.realpath('')
Explanation: Ya! There's two contigs.
End of explanation
<END_TASK>