How do I put form field sets in jQuery UI tabs?
If you're adding javascript for a specific form, use

$form['#attached'] 

e.g:

$form['#attached']['library'][] = array('system', 'ui.tabs');
$form['#attached']['js'] = array(
  drupal_get_path('module', 'mymodule') . '/my_module_init.js',
);


You might also be interested in field_group, which provides jquery tabs etc.. for entity forms