Some additional great info
http://www.k2distillery.com/2008/12/deploy-infopath-as-feature-with-managed.html
http://www.k2distillery.com/2008/10/deploy-infopath-as-feature.html
Also from the K2 documentation, check out the step by step instructions. (be aware you will also need to have some type of digitally signed form in many cases for this to work 100%)
InfoPath integration using Code Behind
When integrating K2 blackpearl with InfoPath FormServices and the InfoPath form contains Code Behind the following steps will need to be performed:
1. Create your Form, add your C# or VB code, set it to Full Trust and save the template on the local machine
2. Open your K2 Project
3. Open the InfoPath Process Integration Wizard
4. Select Add
5. Browse to your Template saved in step 1
6. On the Deployment Location page select Local or Network location
7. Complete the Add InfoPath Template and InfoPath Integration wizards
8. Deploy your process when done with your design
9. After successful deployment browse to the Deployment Location selected in step 6
10. Right Click the file and select Design
11. Select Publish from the File menu
12. Enter your Site URL and click Next
13. Select Enable this form to be filled in Using a browser and Continue to the next page
14. Enter the Template filename which will have to be uploaded by an administrator using the Central Admin and complete the rest of the wizard
15. Close InfoPath
16. Open the MOSS Central Admin site
17. Navigate to Central Admin > Application Manager > Manage Form Templates > Upload Form Template
18. Browse to the File saved in step 14 and select Upload
19. When this completed navigate to Central Admin > Application Manager > Manage Form Templates
20. Find the template uploaded in the previous step, open the file’s drop down menu and select Activate Template on Site Collection
21. Select the site on which you would like to use the template and click on OK
22. Browse to the site on which you activated the Template and navigate to the library on which you wish to add the template as a content type
23. Ensure that the Library is set to display as a Web Page and apply the changes
24. Still on the Library settings page find the Content Types Section and select Add from existing site content types
25. Add the Content Type that you enabled on the Site Collection in step 22
26. Navigate to the Document Library and Open the content type added
27. This should now open the Browser